@fireworkweb/eslint-config
Eslint rule configs for Javascript and Vue.js projects.
Installation
yarn add -D @fireworkweb/eslint-config
npm install --dev @fireworkweb/eslint-config
Usage
Currently there are two configs available: js
for pure javascript projects, vue
for Vue.js projects and react
for React projects. The vue
and react
configs already includes the js
config.
After installing, create a .eslintrc.js
file and add this to your config (add only one):
module.exports = {
extends: [
'@fireworkweb/eslint-config/js',
'@fireworkweb/eslint-config/vue',
'@fireworkweb/eslint-config/react',
],
};
Custom Rules
You can customize any rules (js, vue), react) as this example:
module.exports = {
extends: [
'@fireworkweb/eslint-config/js',
],
rules: {
'no-console': 'off',
},
};
You can also (and probably will) add any specific global variable:
module.exports = {
extends: [
'@fireworkweb/eslint-config/vue',
],
globals: {
Vue: true,
_: true,
Nova: true,
},
};
License
MIT.