Stackblitz: How to import Bootstrap CSS framework

前端 未结 8 932
死守一世寂寞
死守一世寂寞 2020-12-31 02:52

I just found the amazing Stackblitz online VS Code editor. I created an Angular project and under dependencies installed the Bootstrap CSS framework but how

相关标签:
8条回答
  • 2020-12-31 03:39

    Check this StackBlitz example : https://stackblitz.com/edit/angular-wkc7ix?file=styles.css

    It does have a angular-cli.json file and a style.css file

    angular-cli.json :

    {
      "apps": [{
        "styles": ["styles.css"]
      }]
    }
    

    style.css :

    @import "bootstrap/dist/css/bootstrap.min.css";
    
    0 讨论(0)
  • 2020-12-31 03:42

    In angular.json:

    "styles": [
        "node_modules/bootstrap/dist/css/bootstrap.min.css",
        "styles.css"
    ],
    

    For me works just fine.

    0 讨论(0)
提交回复
热议问题