- cnpm/npm install bootstrap@4.0.0-alpha.6 tether jquery –save
- package.json 中可进行查看安装是否成功和版本号
- 在angular.json中进行配置在
(找到路径地址:node_modules/_bootstrap@4.0.0-alpha.6@bootstrap/dist/css)
拷贝bootstra.css的路径地址到angular.json的”styles”下面将bootstrap.js中的路径复制。配置到”scripts”中
"styles": [
"src/styles.css",
"./node_modules/_bootstrap@4.0.0-alpha.6@bootstrap/dist/css/bootstrap.css"
],
"scripts": [
"./node_modules/_bootstrap@4.0.0-alpha.6@bootstrap/dist/js/bootstrap.js"
],