Global SCSS, component.ts.scss, styles


Topic: Global SCSS, component.ts.scss, styles

aganeto asked 6 years ago

When editing syles, a lot of times when I set styles on mycomponent.ts.scss it doesnt change my styles.

Question: 1. Where should I change my styles then ? 2. How about pro/global.scss, free/variables, etc ?


Bartłomiej Malanowski staff pro premium commented 6 years ago

Do you use MDB Angular?


aganeto commented 6 years ago

Yes. I do use MDB Angular


Damian Gemza staff answered 6 years ago

Dear aganeto,

Styles are encapsulated, so you have two possible ways to overwrite existing MDB / Bootstrap styles: 1) Add it to the global styles.scss file (this is quite good approach), 2) Use ViewEncapsulation.None in your component.ts file, and now you're able to overwrite the styles in component.scss file (this is bad approach).

Best Regards,

Damian


Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Answered

Specification of the issue
  • User: Free
  • Premium support: No
  • Technology: General Bootstrap questions
  • MDB Version: -
  • Device: All
  • Browser: All
  • OS: All
  • Provided sample code: No
  • Provided link: No