canirequire

canirequire › ESM-only › eslint-plugin-jsdoc

Is eslint-plugin-jsdoc ESM-only? Can you require() it?

JSDoc linting rules for ESLint.

Last verified Sep 9, 2026 against eslint-plugin-jsdoc@64.3.8. Markdown · JSON

ESM-only ESM-only since 64.0.0 — last CommonJS version is 63.3.3

eslint-plugin-jsdoc dropped its CommonJS build in 64.0.0 (August 2026). The last version with a plain require()-able CommonJS entry is 63.3.3, published Aug 2, 2026; it declares support for Node.js ^22.13.0 || >=24.

On Node.js 22.12+ and newer (eslint-plugin-jsdoc@64.3.8 declares Node.js ^22.22.2 || >=24.15.0), require("eslint-plugin-jsdoc") works with the latest version: Node.js loads synchronous ES modules through require(). Verified on Node.js 22, 24 and 26. Node.js 18 has no require(esm), and eslint-plugin-jsdoc@64.3.8 declares Node.js ^22.22.2 || >=24.15.0, so 18 is outside its supported range anyway.

eslint-plugin-jsdoc@64.3.8 declares engines "^22.22.2 || >=24.15.0", so Node.js 18, 20 are outside its supported range regardless of module format.

What to do

  1. On Node.js 22.12+ and newer (eslint-plugin-jsdoc@64.3.8 declares Node.js ^22.22.2 || >=24.15.0), require("eslint-plugin-jsdoc") works with the latest version: Node.js loads synchronous ES modules through require(). Verified on Node.js 22, 24 and 26.
  2. From a CommonJS file, use a dynamic import inside an async function: const eslintPluginJsdoc = await import("eslint-plugin-jsdoc"). That works on every Node.js version the package supports (^22.22.2 || >=24.15.0).
  3. If you need a synchronous require(): npm install eslint-plugin-jsdoc@63.3.3, the last CommonJS release (published Aug 2, 2026); it declares Node.js ^22.13.0 || >=24.
  4. eslint-plugin-jsdoc@64.3.8 declares engines "^22.22.2 || >=24.15.0", so Node.js 18, 20 are unsupported regardless: upgrade Node.js or pin an older release.
  5. TypeScript: types are bundled; install nothing extra.
Latest
64.3.8 (Sep 9, 2026)
Module format
ESM-only
Last CommonJS version
63.3.3
ESM-only since
64.0.0 (Aug 7, 2026)
TypeScript types
Bundled
Node engines
^22.22.2 || >=24.15.0
Weekly downloads
5.8M
License
BSD-3-Clause

Does eslint-plugin-jsdoc@64.3.8 actually load? Runtime test results

Installed and executed on Sep 9, 2026 with require("eslint-plugin-jsdoc") from a CommonJS file and import "eslint-plugin-jsdoc" from an ES module.

Runtimerequire("eslint-plugin-jsdoc")import "eslint-plugin-jsdoc"
Node.js 18✗ failsERR_REQUIRE_ESM✗ failsSyntaxError
Node.js 20✓ works✓ works
Node.js 22✓ works✓ works
Node.js 24✓ works✓ works
Node.js 26✓ works✓ works
Bun 1.4.0✓ works✓ works

How to import eslint-plugin-jsdoc

ES modules (import)

import * as eslintPluginJsdoc from "eslint-plugin-jsdoc";

Namespace import shown because the ESM entry may have no default export; use named imports for what it exports.

CommonJS (require)

// Node.js 22.12+ and newer (verified):
const eslintPluginJsdoc = require("eslint-plugin-jsdoc");

// Any Node.js version the package supports (^22.22.2 || >=24.15.0), from an async function:
async function main() {
  const eslintPluginJsdoc = await import("eslint-plugin-jsdoc");
}

// Or pin the last CommonJS release (declares Node.js ^22.13.0 || >=24):
// npm install eslint-plugin-jsdoc@63.3.3

Module format by version

Derived from the type, main and exports fields of every stable release on npm, corrected where a runtime test of that version contradicted them (863 versions; the newest 60 shown).

VersionsFormatFirst published
64.0.0 – 64.3.8ESM-onlyAug 7, 2026
61.7.1 – 63.3.3Dual (CommonJS + ESM)Jan 8, 2026

Frequently asked

Is eslint-plugin-jsdoc ESM-only?

eslint-plugin-jsdoc@64.3.8 is ESM-only. eslint-plugin-jsdoc dropped its CommonJS build in 64.0.0 (August 2026). The last version with a plain require()-able CommonJS entry is 63.3.3, published Aug 2, 2026; it declares support for Node.js ^22.13.0 || >=24.

Which version of eslint-plugin-jsdoc still supports CommonJS / require()?

63.3.3 is the last version of eslint-plugin-jsdoc with a CommonJS build; it declares Node.js ^22.13.0 || >=24. Install it with "npm install eslint-plugin-jsdoc@63.3.3". Every version from 64.0.0 on is ESM-only.

How do I use eslint-plugin-jsdoc from a CommonJS file?

From a CommonJS file, use a dynamic import inside an async function: const eslintPluginJsdoc = await import("eslint-plugin-jsdoc"). That works on every Node.js version the package supports (^22.22.2 || >=24.15.0). On Node.js 22.12+ and newer (eslint-plugin-jsdoc@64.3.8 declares Node.js ^22.22.2 || >=24.15.0), require("eslint-plugin-jsdoc") works with the latest version: Node.js loads synchronous ES modules through require(). Verified on Node.js 22, 24 and 26. Alternatively pin eslint-plugin-jsdoc@63.3.3 (declares Node.js ^22.13.0 || >=24).

Does eslint-plugin-jsdoc work in Bun?

Yes. import "eslint-plugin-jsdoc" loaded successfully in Bun 1.4.0 on Sep 9, 2026.

Does eslint-plugin-jsdoc ship TypeScript types?

Yes. eslint-plugin-jsdoc bundles its own type declarations; no @types package is needed.

Links

Other esm-only packages

Similar popularity