0.0.0-SEMANTICALLY-RELEASED • Published 6 years ago
eslint-ts-config-mailonline v0.0.0-SEMANTICALLY-RELEASED
eslint-ts-config-mailonline
MailOnline ESlint Typescript configuration.
Usage
Add eslint-ts-config-mailonline, eslint, typescript, prettier, husky, and pretty-quick as development dependencies:
yarn add --dev eslint-ts-config-mailonline eslint typescript prettier husky pretty-quickCreate ESLint configuration file (.eslintrc.json) that extends eslint-ts-config-mailonline:
{
"extends": "eslint-ts-config-mailonline"
}Create prettier.config.js on the root of your project with these contents:
module.exports = require('eslint-ts-config-mailonline/prettier');Add the following script command to your package.json:
{
"lint": "tsc --noEmit && eslint --ignore-path .gitignore './**/*.{js,jsx,ts,tsx}'"
}and the following pre-commit hook:
"husky": {
"hooks": {
"pre-commit": "pretty-quick --staged && yarn run lint"
}
}Extended configs
The package also has separate entry points for some environments. Simply extend from the entry point as described below
{
"extends": ["eslint-ts-config-mailonline", "eslint-ts-config-mailonline/react"]
}react
{
"extends": "eslint-ts-config-mailonline/react"
}Breaking changes
Any changes to this package that might cause code using it to not validate anymore, will be a semver-major change.
0.0.0-SEMANTICALLY-RELEASED
6 years ago