diff --git a/.changeset/26206-cli-esm-entries.md b/.changeset/26206-cli-esm-entries.md new file mode 100644 index 00000000000..4f32e64e33d --- /dev/null +++ b/.changeset/26206-cli-esm-entries.md @@ -0,0 +1,10 @@ +--- +'@objectstack/cli': patch +--- + +docs(cli): the README says the three code subpaths are ESM + +Clause-②: no +Metadata-protocol: none + +`@objectstack/cli`'s README now states that `.`, `./console` and `./hook-body` are ES modules: load them with `import`, and from CommonJS with `import()`, or with `require()` only on a Node that loads ES modules synchronously (22.12 and later). No export map or code changes. diff --git a/packages/cli/README.md b/packages/cli/README.md index 32a44cf7e56..5bcd7bbd15f 100644 --- a/packages/cli/README.md +++ b/packages/cli/README.md @@ -377,6 +377,8 @@ resolve is exactly this map — a subpath is added here on purpose, with a | `@objectstack/cli/hook-body` | The hook-body extractor `os build` and `os lint` apply, for an app harness that must run the **same** body-only lowering the build ships (below). | | `@objectstack/cli/package.json` | The manifest itself, for the ordinary tooling idiom of reading a dependency's own version. | +The three code subpaths (`.`, `./console`, `./hook-body`) are **ESM**: the package is `"type": "module"` and each maps to an ES module. Load them with `import`. A CommonJS caller reaches them through `import()`, or through `require()` only on a Node that loads ES modules synchronously (22.12 and later). + ### `@objectstack/cli/hook-body` ```typescript