1

Hi Stackoverflow community !

Just a simple question to be sure, I am implementing Ng-Bootstrap in my Angular 4 project using the following link Getting started ng-bootstrap and I've got a doubt about lines number 2 they says: " The only required dependencies are: Bootstrap CSS ", but what does it mean exactly? Because when you click on the hyperlink on the same sentence it brings you there Download bootstrap link there's plenty files (bootstrap.grid.css, boostrap.reboot.css, etc..). So according to theses files my question is: should I had all theses files and their links to my projects assets and into my angular-cli.json "styles" and "scripts" or just bootstrap.min.css should be enough?

Note that I actually need just the "datepicker" element. (maybe more later in the project..)

Thanks in advance for your opinions and answeres

1 Answer 1

4

This means that you need to include the bootstrap styles. Update your .angular-cli.json file to include the bootstrap styles for your app:

"styles": [
     "../node_modules/bootstrap/dist/css/bootstrap.min.css",
    "styles.css",
  ],
Sign up to request clarification or add additional context in comments.

5 Comments

sounds good so I'll just need that, no jquery no bootstrap.js?
if you have followed the tutorial that you mentioned and as you say your are using anuglar-cli, then that's all you need.
you'll also need to install [email protected] from npm using $ npm install --save [email protected]
this morning I start my ng serve --open and I've got this message in the terminlal : Module not found: Error: Can't resolve '/home/papamilo/Documents/Workspace/Test_a2json/front-end_copy_new/node_modules/bootstrap/dist/css/bootstrap.min.css' in '/home/papamilo/Documents/Workspace/Test_a2json/front-end_copy_new/node_modules/@angular/cli/models/webpack-configs' Should I open a new post for that do you think?
here is the link to my new post: stackoverflow.com/questions/45633001/…

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.