Skip to content

Template for ReactJS-TypeScript-Webpack project initial configuration. Includes Jest setup, SCSS Modules configuration.

Notifications You must be signed in to change notification settings

kovalenkovpu/react-ts-template

Repository files navigation

Template repository for manual setup of ReactJS/TypeScript/SCSS Modules project

Dependencies

npm i react react-dom react-router-dom -S

Dev dependencies

Cross-env for arch-agnostic scripts run

npm i cross-env -D

Config

Dev dependencies which are required for the webpack setup to run:

npm i typescript webpack webpack-cli webpack-dev-server webpack-merge ts-loader ts-node ts-jest html-webpack-plugin clean-webpack-plugin copy-webpack-plugin mini-css-extract-plugin sass sass-loader css-loader style-loader -D

Config types

Webpack setup dependencies types:

npm i @types/webpack -D

Testing dependencies

Jest, jest cli handy tests filtering, mocking imports:

npm i jest jest-watch-typeahead identity-obj-proxy jest-environment-jsdom -D

Core types

npm i @types/react @types/react-dom -D

Testing types

Additional testing types (RTL, RTL-Jest, Hooks, User event):

npm i @types/jest @testing-library/dom @testing-library/jest-dom @testing-library/react @testing-library/user-event -D

Linters

Code linting (JS, prettier powered):

npm i eslint eslint-import-resolver-typescript eslint-plugin-import eslint-plugin-react eslint-plugin-react-hooks eslint-webpack-plugin eslint-plugin-prettier eslint-config-prettier -D

Code linting (CSS prettier powered):

npm i stylelint stylelint-config-css-modules stylelint-prettier stylelint-webpack-plugin -D

Linters types

Types for the code linting (JS, CSS):

npm i @typescript-eslint/eslint-plugin @typescript-eslint/parser -D

Code checking

npm i prettier husky -D

Husky also requires additional setup for git hooks.

About

Template for ReactJS-TypeScript-Webpack project initial configuration. Includes Jest setup, SCSS Modules configuration.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published