@fission-codes/eslint-config
v0.1.1
Published
Fission eslint config.
Downloads
6
Readme
eslint-config
Fission eslint, ts and prettier config.
Installation
pnpm install @fission-codes/eslint-config
Usage
package.json
{
"main": "src/index.js",
"types": "dist/src/index.d.ts",
"files": ["dist/src", "src", "index.js", "cli.js"],
"scripts": {
"lint": "eslint . && prettier --check **/*.{js,ts,yml,json} --ignore-path .gitignore && tsc"
},
"simple-git-hooks": {
"pre-commit": "npx lint-staged"
},
"lint-staged": {
"*.{js,ts,md,yml,json}": "prettier --write",
"*": "eslint --fix"
},
"eslintConfig": {
"extends": "@fission-codes",
"ignorePatterns": ["coverage", "dist", "docs"],
// for preact
"settings": {
"react": {
"pragma": "h",
"version": "18.0"
}
}
},
"prettier": "@fission-codes/eslint-config/prettier.config.js"
}
tsconfig.json
{
"extends": "@fission-codes/eslint-config/tsconfig.json",
"compilerOptions": {
"outDir": "dist",
"noEmit": true, // for apps or anything that is not published to npm
"emitDeclarationOnly": true, // for TS with JSDocs
"module": "NodeNext", // for TS packages
"moduleResolution": "NodeNext" // for TS packages
},
"include": ["src", "test"]
}
In monorepos you can install @fission-codes/eslint-config
only in the root and extend the root tsconfig.json
in the packages.
Contributing
Read contributing guidelines here.
License
This project is licensed under either of
- Apache License, Version 2.0, (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option.
Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.