cra-template-router

A custom Create React App template that includes react-router.


Keywords
react, react-router, react-router-dom, create-react-app, template
License
MIT
Install
npm install cra-template-router@1.0.0

Documentation

cra-template-router

A custom Create React App template that includes a basic react-router implementation to kick-start your React projects.

It keeps exactly the same structure as the default template and adds a basic setup for using routes.

Usage

npx

npx create-react-app my-app --template router

npm

npm init react-app my-app --template router

yarn

yarn create react-app my-app --template router

Folder structure

After creation, your project should look like this:

my-app/
  README.md
  node_modules/
  package.json
  public/
    index.html
    favicon.ico
  src/
    pages/
      About.js
      Home.js
    App.css
    App.js
    App.test.js
    index.css
    index.js
    logo.svg

@ismamz