canirequire › Dual (CommonJS + ESM) › release-it
Is release-it ESM-only? Can you require() it?
Generic CLI tool to automate versioning and package publishing-related tasks.
Last verified Sep 9, 2026 against release-it@21.0.2. JSON
Dual (CommonJS + ESM) Dual package — both require() and import work
release-it publishes both a CommonJS entry and a native ESM entry (ESM added in 15.0.0). require("release-it") and import "release-it" both work on every supported Node.js version and in Bun.
Does release-it@21.0.2 actually load? Runtime test results
Installed and executed on Sep 9, 2026 with require("release-it") from a CommonJS file and import "release-it" from an ES module.
| Runtime | require("release-it") | import "release-it" |
|---|---|---|
| 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 | ✓ works | ✓ works |
A failing require() on a CommonJS package usually means the package needs a browser/DOM global, a peer dependency, or a native binary that is not available in a bare Node.js process.
How to import release-it
ES modules (import)
import releaseIt from "release-it";CommonJS (require)
const releaseIt = require("release-it");Module format by version
Derived from the type, main and exports fields of every stable release on npm (345 versions; the newest 60 shown).
| Versions | Format | First published |
|---|---|---|
| 17.4.1 – 21.0.2 | Dual (CommonJS + ESM) | Jul 1, 2024 |
| 15.10.5 – 17.4.0 | ESM-only | Jun 2, 2023 |
Frequently asked
Is release-it ESM-only?
release-it@21.0.2 ships CommonJS and ESM builds. release-it publishes both a CommonJS entry and a native ESM entry (ESM added in 15.0.0). require("release-it") and import "release-it" both work on every supported Node.js version and in Bun.
Can I require release-it?
Yes. release-it ships a CommonJS entry, so require("release-it") works on every Node.js version, alongside the native ESM entry for import.
Does release-it work in Bun?
Yes. import "release-it" loaded successfully in Bun 1.4 on Sep 9, 2026.
Does release-it ship TypeScript types?
Yes. release-it bundles its own type declarations; no @types package is needed.
Links
Other dual (commonjs + esm) packages
- minimatch 10.2.6Dual
- brace-expansion 5.0.9Dual
- lru-cache 11.5.2Dual
- glob 13.0.6Dual
- eslint-visitor-keys 5.0.1Dual
- yallist 5.0.0Dual
- balanced-match 4.0.4Dual
- js-yaml 5.4.1Dual
Similar popularity
- sinon-chai 4.0.1ESM-only
- jasmine-spec-reporter 7.0.0CommonJS
- eslint-plugin-standard 5.0.0CommonJS
- eslint-plugin-html 8.2.0CommonJS
- babel-plugin-transform-class-properties 6.24.1CommonJS
- eslint-import-resolver-webpack 0.13.11CommonJS
- styled-system 5.1.5CommonJS
- prettier-eslint 17.1.2ESM-only