An ESLint plugin that provides a processor to lint files using eslint-env comments in an ESLint flat config. Version 0.6.0 requires ESLint >=8.21 and ships TypeScript types. It allows developers to specify environments per file via /* eslint-env */ comments, including plugin-defined environments like cypress/globals or react-native/react-native. Key differentiator: integrates eslint-env comment functionality into the flat config system, which is not natively supported by ESLint's flat config.
npm install eslint-plugin-eslint-envNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows how to use the EslintEnvProcessor in an ESLint flat config file (eslint.config.js with ESM imports).
Switch to flat config by using eslint.config.js and ensure ESLint version >=8.21.
Use processor: new EslintEnvProcessor() in your config object.
Pass plugins to the processor: new EslintEnvProcessor({ plugins: { 'cypress': eslintPluginCypress } }).Run npm install -D eslint-plugin-eslint-env and ensure node_modules is present.
Ensure you use import { EslintEnvProcessor } from 'eslint-plugin-eslint-env' and instantiate: new EslintEnvProcessor().Verify your eslint.config.js exports an array with an object containing 'files' and 'processor' properties.