An ESLint plugin that provides a custom parser and rules for linting CoffeeScript source files. Version 0.1.15 requires CoffeeScript >=2.5.0 and ESLint >=6.0.0. It adapts the CoffeeScript compiler's AST to be compatible with ESLint, enabling many existing ESLint rules to work with CoffeeScript, and also supplies CoffeeScript-specific rules and compatible versions of rules from popular plugins like eslint-plugin-react, eslint-plugin-import, eslint-plugin-react-native, and eslint-plugin-jsx-a11y. The project is actively maintained with recent fixes for code path analysis and shorthand-this rule.
npm install eslint-plugin-coffeeVerified import paths — ran on the pinned version, not inferred.
Configures ESLint to lint CoffeeScript files using the custom parser and the eslint-plugin-coffee plugin, with a mix of CoffeeScript-specific and standard ESLint rules.
If you relied on `id-length` being recommended, you must explicitly enable it: `'coffee/id-length': 'error'`.
Check the supported rules list in the README before enabling standard rules. Use `'coffee/rule-name'` for compatible versions.
Ensure your project uses CoffeeScript 2.5.0+ and ESLint 6.0.0+.
Refer to the README for supported CoffeeScript version and be aware that some newer CoffeeScript features might not be linted correctly.
Update to v0.1.13 or later to get proper handling of spread props.
Update to v0.1.14 or later to avoid potential crashes with code path analysis.
Use CommonJS or transpile your CoffeeScript project before linting.
Ensure `eslint-plugin-coffee` is installed as a dev dependency: `npm install --save-dev eslint-plugin-coffee`.
Add `"plugins": ["coffee"]` to your ESLint config.
Ensure you have set `"parser": "eslint-plugin-coffee/parser"` in your ESLint config and that your CoffeeScript version is >= 2.5.0.
Run `npm install --save-dev coffeescript@^2.5.0`.