Skip to content

My CRA templates + scripts to build templates from working CRA applications.

License

Notifications You must be signed in to change notification settings

stocky37/cra-templates

Repository files navigation

cra-templates

Packages

  • cra-template scripts
  • template-stocky37
    • cra-template-stocky37 (generated)

Scripts

build:fresh

As build fails if run when the generated template workspaces do not exist yet, this script aims to run a build that should always succeed.

Templates

cra-template-stocky37

This is my own personal template and includes the following on top of the base cra-template:

  • react-router v6 for routing
  • react-query for fetching data
  • json-server for mocking JSON APIs locally
  • allow absolute imports from the src directory
  • Dockerfiles for both development and production use
  • can pull envvars from window.env (set in /config.js) or process.env
  • eslint configured with airbnb base and sane defaults
  • prettier configured with my own preferred configuration
  • pretty-package-json configured with defaults for keeping package.jsons prettified and deterministically ordered
  • husky & lint-staged configured to run eslint, prettier and pretty-package-json in a pre-commit hook
  • @welldone-software/why-did-you-render for helping debug rerender issues in development

About

My CRA templates + scripts to build templates from working CRA applications.

Topics

Resources

License

Stars

Watchers

Forks