@espcom/eslint-config
v0.0.8
Published
Private ESLint config
Downloads
3
Readme
Private ESLint config
Usage
- Add
@espcom/eslint-config
todevDependencies
in package.json - Create
eslint.config.cjs
with content:
const path = require('path');
const { getEslintConfig } = require('@espcom/eslint-config');
const eslintConfig = getEslintConfig({
tsConfigPath: path.resolve(__dirname, './tsconfig.json'),
});
module.exports = eslintConfig;
- Add scripts to package.json (example for formatting only pointed files but analyze all files):
{
"scripts": {
"analyze:js": "eslint ./src",
"format:js": "eslint --fix"
}
}
Attach ESLint to your IDE, don't forget to enable auto-formatting on save.