[Solved] The `/deep/` selector is not working using sass-loader in my VueJS application

In my Vue components, I am trying to use the /deep/

<style lang="scss" scoped>
  .parent-container {
    & /deep/ .child-comp {
      background-color: tomato;
      color: white;
    }
  }
</style>

 Solution: This is because /deep/is not supported by sass. You need to explicitly set your sass-loader to use node-sasslike this:

loader: 'sass-loader', options: { implementation: require('node-sass')

 

Was this post helpful?
Let us know if you liked the post. That’s the only way we can improve.
Yes0
No0
Harinder Singh

Harinder Singh

My name is Harinder Singh and I specialize in Software industry. I consider myself as a life learner. I love learning new concepts, embracing new ideas and reading and searching for innovation.