1.0.2 • Published 4 years ago
cra-template-nami v1.0.2
CRA-MHL
My Create React App (CRA) primary template
A very opinionated starter Create React App (CRA) template with:
- React
- State management - Recoil
- CSS Framework - TailwindCSS
- CSS-in-JS Modules — Styled Components
- Router - React Router
- Unit Testing - React Testing Library
- Folder structure
- Format & Lint - ESLint & Prettier
- Useful utilities - Classnames, React-Helmet.
Custom Templates, format, and ESLint configurations.
Usage
yarn create react-app your-project-name --template cra-template-namiOr;
npx create-react-app your-project-name --template cra-template-naminpx package runner tool installs the most recent stable version of CRA from npm. (npx comes out of the box with npm 5.2+)
--template parameter points to this template, note that cra-template- prefix will be omitted.
Run Scripts
Inside the project directory run:
yarn start- runs the app in the development mode. Open http://localhost:3000 to view it in the browser.yarn test- launches the test runner in the interactive watch mode.yarn build- builds the app for production to thebuildfolder.yarn eject- exposes content ofreact-scriptpackageyarn lint- lints project files according to Airbnb — as part of their style guide 👍 — it provides an ESLint configuration that anyone can use and it is the standard.yarn fix- fix lints issues according to style guide set.yarn format- will format your code prettier using opinionated settings inside.prettierrcfile.yarn isready- will check if the code is ready for showtime (production), run lint, format and build.
CRA template only support scripts and dependencies inside generated package.json. No devDependencies is possible on CRA template for now.
If you like this library, don't be shy to star it 🙏