eslint.config.js — astro Source File
Architecture documentation for eslint.config.js, a javascript file in the astro codebase. 4 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR dc6b593d_89bd_dfd3_aeb5_9056af780502["eslint.config.js"] c52a5f83_66e3_37d7_9ebb_767f7129bc62["node:path"] dc6b593d_89bd_dfd3_aeb5_9056af780502 --> c52a5f83_66e3_37d7_9ebb_767f7129bc62 d9a92db9_c95e_9165_13ac_24b3d859d946["node:url"] dc6b593d_89bd_dfd3_aeb5_9056af780502 --> d9a92db9_c95e_9165_13ac_24b3d859d946 07f652be_3752_0b5d_6e1c_ff4d2c495eea["eslint-plugin-regexp"] dc6b593d_89bd_dfd3_aeb5_9056af780502 --> 07f652be_3752_0b5d_6e1c_ff4d2c495eea 55664275_6e05_4241_bb2b_f89ea93b224e["typescript-eslint"] dc6b593d_89bd_dfd3_aeb5_9056af780502 --> 55664275_6e05_4241_bb2b_f89ea93b224e style dc6b593d_89bd_dfd3_aeb5_9056af780502 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import path from 'node:path';
import { fileURLToPath } from 'node:url';
// plugins
import regexpEslint from 'eslint-plugin-regexp';
import tseslint from 'typescript-eslint';
const typescriptEslint = tseslint.plugin;
// parsers
const typescriptParser = tseslint.parser;
const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
export default [
// If ignores is used without any other keys in the configuration object, then the patterns act as global ignores.
// ref: https://eslint.org/docs/latest/use/configure/configuration-files#globally-ignoring-files-with-ignores
{
ignores: [
'**/.*',
'**/*.d.ts',
'packages/**/*.min.js',
'packages/**/dist/',
'packages/**/fixtures/',
'packages/**/_temp-fixtures/',
'packages/astro/vendor/vite/',
'benchmark/**/dist/',
'benchmark/static-projects/**',
'examples/',
'scripts/',
'.github/',
'.changeset/',
],
},
...tseslint.configs.recommendedTypeChecked,
...tseslint.configs.stylisticTypeChecked,
regexpEslint.configs['flat/recommended'],
{
languageOptions: {
parser: typescriptParser,
parserOptions: {
project: ['./packages/*/tsconfig.json', './tsconfig.eslint.json'],
tsconfigRootDir: __dirname,
},
},
plugins: {
'@typescript-eslint': typescriptEslint,
regexp: regexpEslint,
},
rules: {
// These off/configured-differently-by-default rules fit well for us
'@typescript-eslint/switch-exhaustiveness-check': 'error',
'@typescript-eslint/no-shadow': 'error',
'no-console': 'off',
// Todo: do we want these?
'@typescript-eslint/no-unused-vars': [
'error',
{
// ... (101 more lines)
Dependencies
- eslint-plugin-regexp
- node:path
- node:url
- typescript-eslint
Source
Frequently Asked Questions
What does eslint.config.js do?
eslint.config.js is a source file in the astro codebase, written in javascript.
What does eslint.config.js depend on?
eslint.config.js imports 4 module(s): eslint-plugin-regexp, node:path, node:url, typescript-eslint.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free