Including bootstrap style only for one module

Viewed 1927

I have an Angular 5 application. I wonder if there is anyway to import bootstrap or any other library only for one module in Angular 5?

1 Answers

If you don't want to include bootstrap file globally in an angular project then you can import bootstrap file in a components CSS file. So in every component.css in which you need a bootstrap, there you can write like this on top of the file.

@import "~bootstrap/dist/css/bootstrap.css";
Related