GithubHelp home page GithubHelp logo

reactstrap_installation_guidance's Introduction

Quick guidance for installing reactstrap in React

The procedures of installing reactstrap can sometimes be confusing. This guidance is for the developers we want to install reactstrap quickly to their React projects. The App.js file in this repo shows a navigation bar of reactstrap / Bootstrap.

Let's start!

1. Install create-react

  • Run npm install -g create-react-app.
  • Run create-react-app my-app.
  • Run cd my-app.
  • Run npm start (Alternatively, you can skip it and execute it at Step 4).

2. Install reactstrap and peer dependencies via NPM

Run `npm install --save reactstrap react react-dom

(You can open another terminal if you skip running npm start).

3. Install Bootstrap

  • Run npm install bootstrap --save.

  • Run npm install --save reactstrap react react-dom.

  • Import Bootstrap CSS to src/index.js:

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

  • Import the chosen reactstrap components to src/App.js or your custom component files:

    import {Element} from 'reactstrap';

4. Add reactstrap code

  • Visit the reactstrap website and choose a component.
  • Add the code of the chosen component to your App.js or other files. Modify it when necessary.
  • Execute npm start if you skip it at Step 1.

5. Add CDN

When you deploy the web app to a server, add a Bootstrap CDN link from here to ensure Bootstrap works properly.

Courtesy of the excellent developer Mr Norbert Angyal and the reactstrap website.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.