@justoss/code-style
v0.2.0
Published
Shareable configurations for JavaScript and TypeScript projects based on Google style guides.
Downloads
39
Maintainers
Readme
@justoss/eslint-config
Shareable configurations for JavaScript and TypeScript projects based on Google style guides.
Getting Started
ESLint configuration
For JS projects
// .eslintrc.js
module.exports = {
extends: [
'./node_modules/@justoss/code-style/eslint-config',
'./node_modules/@justoss/code-style/eslint-config-react',
],
// Your settings...
};
For TS projects
// .eslintrc.js
module.exports = {
extends: [
'./node_modules/@justoss/code-style/eslint-config',
'./node_modules/@justoss/code-style/eslint-config-typescript',
'./node_modules/@justoss/code-style/eslint-config-react',
],
overrides: [
{
files: ['**/*.ts', '**/*.tsx'],
parserOptions: {
tsconfigRootDir: '.',
project: ['./tsconfig.json'],
},
},
],
// Your settings...
};
Prettier configuration
// .prettier-config.js
module.exports = require('@justoss/code-style/prettier-config');