Stackblitz: How to import Bootstrap CSS framework

前端 未结 8 1065
死守一世寂寞
死守一世寂寞 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:33

    Quite an old question but anyway this will be helpful for any one looking to include bootstrap in Stackblitz.

    Step 1: Go to app.module.ts and write

    import { NgbModule } from '@ng-bootstrap/ng-bootstrap';
    

    Stackblitz will automatically prompts you for installing ng-bootstrap module.

    Step 2: Add NgbModule in imports array.

    imports:      [ BrowserModule, FormsModule, NgbModule ],
    

    Step 3: In your styles.css

    @import '~bootstrap/dist/css/bootstrap.min.css';
    

    Now you should be getting glyphicons in your Angular project.

提交回复
热议问题