Registry / testing / eslint-plugin-haraka

eslint-plugin-haraka

JSON →
library1.0.16jsnpmunverified

ESLint plugin providing Haraka-specific rules and recommended configuration for Haraka projects. Current stable version is 2.0.4 (as of 2025), with a major breaking change in v2.0.0 that depends on ESLint 9. The plugin enforces best practices for Haraka plugin development, including environment globals, ECMAScript version (es2024), and custom rules like no-unused-vars. It is actively maintained with frequent releases, typically following Haraka core updates. Key differentiators: tailored for Haraka's plugin architecture, includes a 'recommended' config, and integrates with flat config in ESLint 9.

npm install eslint-plugin-haraka
INSTALL
IMPORT
SIG · ESLINT-PLUGIN-HARA
E
eslint-plugin-haraka
testingjavascriptv1.0.16
Install
Import
Disk
Pass rate
0/ 6
Env Coverage0 / 6
glibc
1822
musl
1822
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18226 runs
build_error
glibc
node 18226 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

plugin:haraka/recommended
extends: ['plugin:haraka/recommended']
extends: ['haraka/recommended']
Must include 'plugin:' prefix in ESLint config files.
default (plugin)
import haraka from 'eslint-plugin-haraka'
const haraka = require('eslint-plugin-haraka')
ESM-only; no CommonJS support in v2. Use dynamic import() if needed.
configs.recommended
import { configs } from 'eslint-plugin-haraka'; export default [...configs.recommended]
import haraka from 'eslint-plugin-haraka'; export default [...haraka.recommended]
For flat config (ESLint 9+), access configs via 'configs.recommended'.

Installs the plugin, sets up .eslintrc.yaml with Haraka recommended config, and provides npm scripts for linting and auto-fix.

// .eslintrc.yaml plugins: - haraka extends: - eslint:recommended - plugin:haraka/recommended // package.json { "scripts": { "lint": "npx eslint *.js test", "lintfix": "npx eslint --fix *.js test" } } // Install npm install --save-dev eslint eslint-plugin-haraka // Run lint npm run lint
Debug
Known issues
breakingv2.0.0 drops support for ESLint 8 and below. Requires ESLint 9 or higher.
fix
Upgrade ESLint to v9+ and migrate to flat config if needed. See ESLint migration guide.
affects: >=2.0.0
breakingv2.0.0 removed deprecated formatting rules that were previously included.
fix
Remove any references to removed rules from your config. Use separate formatting tools like Prettier.
affects: >=2.0.0
breakingv1.1.1 removed the 'haraka:recommended' config and rules included in eslint:recommended.
fix
Use 'plugin:haraka/recommended' instead of 'haraka:recommended' and ensure eslint:recommended is also extended.
affects: >=1.1.1
deprecatedThe no-unused-vars rule now includes 'caughtErrorsIgnorePattern' in v2.0.3.
fix
If you customize no-unused-vars, you may need to update your config to respect caught exceptions.
affects: >=2.0.3
gotchaGlobals are now specified as 'readonly' by default since v2.0.2; previously they were set to true.
fix
If you modify globals in your config, ensure they are consistent with 'readonly' or 'writable'.
affects: >=2.0.2
Errors
Common errors & fixes
Error: Cannot find module 'eslint-plugin-haraka'
Plugin not installed or not listed in package.json.
fix
Run 'npm install --save-dev eslint-plugin-haraka' and ensure it's in devDependencies.
Configuration for rule 'haraka/no-unused-vars' is invalid
Rule no longer exists or has been renamed in a newer version.
fix
Check the plugin version; no-unused-vars was added in v1.1.4 but may be removed in later versions. Use eslint's built-in no-unused-vars instead.
ESLint couldn't find the config 'plugin:haraka/recommended'.
The config name is incorrect or the plugin is not properly loaded.
fix
Ensure your .eslintrc uses 'extends: ["plugin:haraka/recommended"]' and the plugin is installed.
Upgrade
Version history
1.0.16latest on npm
Audit
Dependencies
eslintrequiredPeer dependency: requires ESLint 9+ since v2.0.0
@eslint/jsoptionalPeer dependency for ESLint 9 flat config
@eslint/eslintrcoptionalPeer dependency for ESLint 9 backwards compatibility
Agent activity
2 hits · last 30 days
node
2
Resources
eslint-plugin-haraka — npm install eslint-plugin-haraka · libregistry