Skip to content

Latest commit

 

History

History
52 lines (38 loc) · 1.95 KB

readme.md

File metadata and controls

52 lines (38 loc) · 1.95 KB

Sensible vite project starter

Scripts

start: Install dependencies and start dev server

coverage: Generate coverage report and open in Chrome

test: Test in watch mode

test-all: Run all unit and component tests

test-e2e: Run all end-to-end tests

install-latest: Updates all dependencies

Additional notes

  • ESLint configuration:

    • .eslintrc.json: VSCode and vite-checker-plugin
    • .eslintrc.dev.json: pre-commit hook (fast)
    • .eslintrc.prod.json: pre-push hook (slow)
  • useState and useReducer hooks are forbidden via eslint-plugin-no-state-hooks

    • Use XState machines instead
    • Reasoning:
      • Decouples business logic from UI
      • Allows for correct time travel debugging
  • String literals in JSX are forbidden via react/jsx-no-literals

    • Use route to provide props
    • Reasoning:
      • Internationalization
      • Component re-usability