mirror of
https://github.com/perfect-panel/ppanel-web.git
synced 2026-02-10 02:11:19 -05:00
40 lines
763 B
JavaScript
40 lines
763 B
JavaScript
const { resolve } = require('node:path');
|
|
|
|
const project = resolve(process.cwd(), 'tsconfig.json');
|
|
|
|
/*
|
|
* This is a custom ESLint configuration for use with
|
|
* internal (bundled by their consumer) libraries
|
|
* that utilize React.
|
|
*/
|
|
|
|
/** @type {import("eslint").Linter.Config} */
|
|
module.exports = {
|
|
extends: ['eslint:recommended', 'prettier', 'turbo'],
|
|
plugins: ['only-warn'],
|
|
globals: {
|
|
React: true,
|
|
JSX: true,
|
|
},
|
|
env: {
|
|
browser: true,
|
|
},
|
|
settings: {
|
|
'import/resolver': {
|
|
typescript: {
|
|
project,
|
|
},
|
|
},
|
|
},
|
|
ignorePatterns: [
|
|
// Ignore dotfiles
|
|
'.*.js',
|
|
'node_modules/',
|
|
'dist/',
|
|
],
|
|
overrides: [
|
|
// Force ESLint to detect .tsx files
|
|
{ files: ['*.js?(x)', '*.ts?(x)'] },
|
|
],
|
|
};
|