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>
<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet" />
<div class="container py-5">
<div class="row mb-4">
<div class="col-lg-5">
<h2 class="display-4 font-weight-light">Our team</h2>
<p class="font-italic text-muted">Lorem ipsum dolor sit amet, consectetur adipisicing elit.</p>
</div>
</div>
<div class="row text-center">
<div class="col-xl-3 col-sm-6 mb-5">
<div class="bg-white rounded shadow-sm py-5 px-4"><img src="https://bootdey.com/img/Content/avatar/avatar7.png" alt="" width="100" class="img-fluid rounded-circle mb-3 img-thumbnail shadow-sm"/>
<h5 class="mb-0">Manuella Nevoresky</h5><span class="small text-uppercase text-muted">CEO - Founder</span>
<ul class="social mb-0 list-inline mt-3">
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-facebook-f"></i></a></li>
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-twitter"></i></a></li>
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-instagram"></i></a></li>
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-linkedin"></i></a></li>
</ul>
</div>
</div>
<div class="col-xl-3 col-sm-6 mb-5">
<div class="bg-white rounded shadow-sm py-5 px-4"><img src="https://bootdey.com/img/Content/avatar/avatar6.png" alt="" width="100" class="img-fluid rounded-circle mb-3 img-thumbnail shadow-sm"/>
<h5 class="mb-0">Samuel Hardy</h5><span class="small text-uppercase text-muted">CEO - Founder</span>
<ul class="social mb-0 list-inline mt-3">
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-facebook-f"></i></a></li>
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-twitter"></i></a></li>
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-instagram"></i></a></li>
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-linkedin"></i></a></li>
</ul>
</div>
</div>
<div class="col-xl-3 col-sm-6 mb-5">
<div class="bg-white rounded shadow-sm py-5 px-4"><img src="https://bootdey.com/img/Content/avatar/avatar8.png" alt="" width="100" class="img-fluid rounded-circle mb-3 img-thumbnail shadow-sm"/>
<h5 class="mb-0">Tom Sunderland</h5><span class="small text-uppercase text-muted">CEO - Founder</span>
<ul class="social mb-0 list-inline mt-3">
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-facebook-f"></i></a></li>
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-twitter"></i></a></li>
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-instagram"></i></a></li>
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-linkedin"></i></a></li>
</ul>
</div>
</div>
<div class="col-xl-3 col-sm-6 mb-5">
<div class="bg-white rounded shadow-sm py-5 px-4"><img src="https://bootdey.com/img/Content/avatar/avatar2.png" alt="" width="100" class="img-fluid rounded-circle mb-3 img-thumbnail shadow-sm"/>
<h5 class="mb-0">John Tarly</h5><span class="small text-uppercase text-muted">CEO - Founder</span>
<ul class="social mb-0 list-inline mt-3">
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-facebook-f"></i></a></li>
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-twitter"></i></a></li>
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-instagram"></i></a></li>
<li class="list-inline-item"><a href="#/" class="social-link"><i class="fa fa-linkedin"></i></a></li>
</ul>
</div>
</div>
</div>
</div>
</div>
);
}
export default App;
4. Now we need to add below code into our my-awesome-project/src/App.css file :
body{
background:#eee;
margin-top:20px;
}
.img-thumbnail {
padding: .25rem;
background-color: #fff;
border: 1px solid #dee2e6;
border-radius: .25rem;
max-width: 100%;
height: auto;
}
.social-link {
width: 30px;
height: 30px;
border: 1px solid #ddd;
display: flex;
align-items: center;
justify-content: center;
color: #666;
border-radius: 50%;
transition: all 0.3s;
font-size: 0.9rem;
}