mirror of
https://github.com/zos-apps/config.git
synced 2026-11-04 17:34:49 +00:00
43 lines
909 B
JavaScript
43 lines
909 B
JavaScript
/**
|
|
* Base ESLint configuration for zOS apps
|
|
*
|
|
* Usage:
|
|
* ```js
|
|
* // eslint.config.js
|
|
* import config from '@zos-apps/config/eslint';
|
|
* export default config;
|
|
* ```
|
|
*/
|
|
|
|
export default [
|
|
{
|
|
ignores: ['dist/**', 'node_modules/**'],
|
|
},
|
|
{
|
|
files: ['**/*.{ts,tsx}'],
|
|
languageOptions: {
|
|
ecmaVersion: 2022,
|
|
sourceType: 'module',
|
|
parserOptions: {
|
|
ecmaFeatures: {
|
|
jsx: true,
|
|
},
|
|
},
|
|
},
|
|
rules: {
|
|
// TypeScript best practices
|
|
'no-unused-vars': 'off', // TypeScript handles this
|
|
'no-undef': 'off', // TypeScript handles this
|
|
|
|
// React best practices
|
|
'react/react-in-jsx-scope': 'off', // Not needed with React 17+
|
|
'react/prop-types': 'off', // We use TypeScript
|
|
|
|
// Code style
|
|
'prefer-const': 'error',
|
|
'no-var': 'error',
|
|
'eqeqeq': ['error', 'always'],
|
|
},
|
|
},
|
|
];
|