@darion
To install Bootstrap in React.js, you can follow these steps:
- Initialize a new React.js project by running the following command in your command line:
1
|
npx create-react-app your-app-name
|
- Change to the project directory:
- Install Bootstrap as a dependency by running the following command:
- Open the src/index.js file and import the Bootstrap CSS by adding the following line at the top:
1
|
import 'bootstrap/dist/css/bootstrap.css';
|
- Save the changes and start the React development server by running the following command:
Now, Bootstrap is installed and ready to use in your React.js project. You can use Bootstrap classes and components in your JSX files by referring to the Bootstrap documentation.