{"id":19863,"library":"eslint-plugin-node-dependencies","title":"eslint-plugin-node-dependencies","description":"ESLint plugin (v2.2.0, active development) that lints package.json dependencies for issues like missing or mismatched engines, deprecated packages, or improper provenance. Requires Node >= 20.19 and ESLint >= 9.38. Released as needed with minor and patch updates. Differentiated from other ESLint plugins by focusing specifically on dependency metadata integrity rather than code style or security scanning.","status":"active","version":"2.2.0","language":"javascript","source_language":"en","source_url":"https://github.com/ota-meshi/eslint-plugin-node-dependencies","tags":["javascript","eslint","eslintplugin","eslint-plugin","nodejs","dependencies","json"],"install":[{"cmd":"npm install eslint-plugin-node-dependencies","lang":"bash","label":"npm"},{"cmd":"yarn add eslint-plugin-node-dependencies","lang":"bash","label":"yarn"},{"cmd":"pnpm add eslint-plugin-node-dependencies","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"peer dependency; plugin requires ESLint v9.38.0 or higher","package":"eslint","optional":false}],"imports":[{"note":"ESM-only since v2.0.0; CommonJS require() will fail.","wrong":"const nodeDependenciesPlugin = require('eslint-plugin-node-dependencies')","symbol":"default","correct":"import nodeDependenciesPlugin from 'eslint-plugin-node-dependencies'"},{"note":"Named export 'rules' is available directly; do not destructure from default.","wrong":"import plugin from 'eslint-plugin-node-dependencies'; const { rules } = plugin","symbol":"rules","correct":"import { rules } from 'eslint-plugin-node-dependencies'"},{"note":"Named export 'configs' provides flat configs; use plugin.configs.recommended in flat config.","wrong":"import plugin from 'eslint-plugin-node-dependencies'; const { configs } = plugin","symbol":"configs","correct":"import { configs } from 'eslint-plugin-node-dependencies'"}],"quickstart":{"code":"import nodeDependenciesPlugin from 'eslint-plugin-node-dependencies';\n\nexport default [\n  ...nodeDependenciesPlugin.configs.recommended,\n];\n","lang":"typescript","description":"Sets up the recommended rules for eslint-plugin-node-dependencies in an ESLint flat config file."},"warnings":[{"fix":"Migrate from .eslintrc.* to eslint.config.js using flat config format.","message":"v2.0.0 dropped support for legacy (eslintrc) config. Only flat config is supported.","severity":"breaking","affected_versions":">=2.0.0"},{"fix":"Update Node.js to ^20.19.0, ^22.13.0, or >=24.","message":"Requires Node.js ^20.19.0 || ^22.13.0 || >=24. Older Node versions are incompatible.","severity":"breaking","affected_versions":">=2.0.0"},{"fix":"Upgrade ESLint to v9.38.0 or later.","message":"Requires ESLint >=9.38.0. ESLint v8 and older are not supported.","severity":"breaking","affected_versions":">=2.0.0"},{"fix":"Pin exact version in package.json and test upgrades thoroughly.","message":"The plugin is experimental; rules may change without major version bump.","severity":"gotcha","affected_versions":">=1.0.0"},{"fix":"Ensure eslint/json is installed if using JSON-related features.","message":"The package uses eslint-json-compat-utils for compatibility with eslint/json, which may introduce additional behavior for JSON files.","severity":"gotcha","affected_versions":">=2.1.0"}],"env_vars":null,"search_vec":"'20.19':29 '9.38':32 'activ':9 'code':55 'depend':5,14,50,67 'deprec':22 'develop':10 'differenti':41 'engin':21 'eslint':2,6,31,44,61,64 'eslint-plugin':63 'eslint-plugin-node-depend':1 'eslintplugin':62 'focus':47 'improp':25 'integr':52 'issu':16 'javascript':60 'json':68 'like':17 'lint':12 'metadata':51 'minor':37 'mismatch':20 'miss':18 'need':35 'node':4,28 'nodej':66 'packag':23 'package.json':13 'patch':39 'plugin':3,7,45,65 'proven':26 'rather':53 'releas':33 'requir':27 'scan':59 'secur':58 'specif':48 'style':56 'updat':40 'v2.2.0':8","created_at":"2026-04-25T11:20:03.892043+00:00","updated_at":"2026-04-25T11:20:03.892043+00:00","problems":[{"fix":"npm install --save-dev eslint-plugin-node-dependencies","cause":"Package not installed or not in node_modules.","error":"Error: Cannot find module 'eslint-plugin-node-dependencies'"},{"fix":"Use import nodeDependenciesPlugin from 'eslint-plugin-node-dependencies' and spread plugin.configs.recommended.","cause":"Using legacy eslintrc config or incorrect import style.","error":"TypeError: plugin.configs is not a function"},{"fix":"Switch to eslint.config.js with flat config; do not use 'extends' with plugin: prefix.","cause":"Legacy eslintrc config format used; plugin requires flat config.","error":"Error: Failed to load config 'plugin:node-dependencies/recommended'"},{"fix":"Wrap rules in an object with 'plugins' and 'rules' properties.","cause":"Misconfigured flat config: placing rules directly at top level instead of inside a config object.","error":"Error: ESLint configuration is invalid: - Unexpected top-level property \"rules\". Did you mean to use plugins?"}],"ecosystem":"npm","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":"","cli_version":null,"type":"library","homepage":null,"github":"https://github.com/ota-meshi/eslint-plugin-node-dependencies","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/eslint-plugin-node-dependencies","openapi_spec":null,"status_page":null,"smithery":null,"categories":["devops","testing"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-17","next_check":"2026-07-24","install_tag":null}}