1. First, we need fresh reactjs setup, and for that, we need to run below commands into out terminal, and also we should have latest node version installed on our system:
npx create-react-app my-awesome-project
cd my-awesome-project
npm start
2. Now we need to run below commands into our project terminal to get bootstrap and related modules into our reactjs application:
npm install [email protected] --save
npm start //For start project again
3. Finally for the main output, we need to add below code into our my-awesome-project/src/App.js file or if you have fresh setup then you can replace my-awesome-project/src/App.js file code with below code:
import React from 'react';
import './App.css';
import 'bootstrap/dist/css/bootstrap.min.css';
function App() {
return (
<div>
<div class="container bootdey">
<hr/>
<div class="wrap clearfix">
<div class="col-sm-4 col-xs-12 avatar">
<img src="https://bootdey.com/img/Content/avatar/avatar7.png" class="img-thumbnail" alt="" />
<p>#username</p>
</div>
<div class="col-sm-8 col-xs-12">
<div class="icons col-xs-12">
<a href="#/" class="btn btn-default"><span class="glyphicon glyphicon-envelope"></span></a>
<a href="#/" class="btn btn-default"><span class="glyphicon glyphicon-user"></span></a>
<a href="#/" class="btn btn-default"><span class="glyphicon glyphicon-bookmark"></span></a>
<a href="#/" class="btn btn-default"><span class="glyphicon glyphicon-refresh"></span></a>
<a href="#/" class="btn btn-default"><span class="glyphicon glyphicon-trash"></span></a>
</div>
<div class="col-xs-12 content">
<h2>John Doe</h2>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Eos a similique dicta modi minus nostrum magnam provident reprehenderit in quae</p>
<p>
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Eos a similique dicta modi minus nostrum magnam provident reprehenderit in quae </p>
<p>
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Eos a similique dicta modi minus nostrum magnam provident reprehenderit in quae </p>
<p>
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Eos a similique dicta modi minus nostrum magnam provident reprehenderit in quae </p>
</div>
</div>
</div>
</div>
</div>
);
}
export default App;