Install Bootstrap with NPM
Install Bootstrap
1
npm install bootstrap@4.3.1 --save
4.3.1
is bootstrap versionBootstrap many of our components require the use of JavaScript to function. Specifically, they require jQuery, Popper.js, and our own JavaScript plugins.
1
npm install jquery@3.3.1 --save
1
npm install popper.js@1.14.7 --save
3.3.1
is jQuery version,1.14.7
is Popper.js version
[Optional] Add to Angular project
1
2
3
4
5
6
7
8
9"styles": [
"node_modules/bootstrap/dist/css/bootstrap.min.css",
"src/styles.scss"
],
"scripts": [
"node_modules/jquery/dist/jquery.slim.min.js",
"node_modules/popper.js/dist/popper.min.js",
"node_modules/bootstrap/dist/js/bootstrap.min.js"
]Add the CSS and JS to
angular.json
file, when the start will load.