Adding bootstrap 4 to an ionic 4 project

What ever the framework may be, it is often handy to have bootstrap in your favorite application.

With it’s plethora of styling definitions, bootstrap indeed is favorite for all web developers, let’s get started.

Firstly, install bootstrap in your project by following command.

npm install bootstrap

 

Open angular.json that is in your root of your project workspace and add the below line.

You are going to add the path for bootstrap.

"styles": [
              {
                "input": "src/theme/variables.scss"
              },
              {
                "input": "src/global.scss"
              },
              {
                "input": "node_modules/bootstrap/dist/css/bootstrap.min.css"
              }
            ],

And finally, restart your ionic app.

We are done.

ALSO READ  Angular 6 - Routing and Navigation (with Child Routes & Route Auth Guards)