@bs-solutions/cra-template-bast-router

1.0.1 • Public • Published

React template for create-react-app with React Router

This is the template for Create React App created by Bastion team.

Stack

  • eslint (Airbnb)
  • prettier
  • typescript
  • sass (scss)

Install

To use this template, add --template @bs-solutions/bast-router when creating a new app.

For example:

npx create-react-app bastion-app-name --template @bs-solutions/bast-router

# or

yarn create react-app bastion-app-name --template @bs-solutions/bast-router

File architecture

Recommended file architecture:

  • assets
  • components
  • contexts
  • i18n
  • services
  • utils
  • views

Example

── /src
    ├── /assets
    ├── /components
    │   ├── /forms
    │   │   ├── /TextField
    │   │   │   ├── TextField.ts
    │   │   │   ├── TextField.module.scss
    │   │   │   └── TextField.test.ts
    │   │   ├── /Select
    │   │   │   ├── Select.ts
    │   │   │   ├── Select.styles.ts
    │   │   │   └── Select.test.ts
    │   │   └── index.ts
    │   ├── /routing
    │   │   └── /PrivateRoute
    │   │       ├── /PrivateRoute.ts
    │   │       └── /PrivateRoute.test.ts
    │   └── /layout
    │       └── /navigation
    │           └── /NavBar
    │              ├── NavBar.ts
    │              ├── NavBar.module.scss
    │              └── NavBar.test.ts
    ├── /contexts
    ├── /i18n
    ├── /services
    │   ├── /LocalStorage
    │   │   ├── LocalStorage.ts
    │   │   └── LocalStorage.test.ts
    │   └── index.ts
    ├── /utils
    │   ├── /constants
    │   │   └── countries.ts
    │   └── /helpers
    │       ├── validation.ts
    │       ├── currency.ts
    │       └── array.ts
    ├── /views
    │   ├── Home.tsx
    │   └── About.tsx
    ├── App.module.scss
    ├── App.test.tsx
    ├── App.tsx
    └── index.tsx

More

For more information, please refer to:

Package Sidebar

Install

npm i @bs-solutions/cra-template-bast-router

Weekly Downloads

1

Version

1.0.1

License

MIT

Unpacked Size

110 kB

Total Files

64

Last publish

Collaborators

  • sudondie
  • vladsolyony
  • dmitriy-u
  • vperekrestov