-
-
Notifications
You must be signed in to change notification settings - Fork 123
Closed as duplicate of#153
Labels
👎 phase/noPost cannot or will not be acted onPost cannot or will not be acted on👯 no/duplicateDéjà vuDéjà vu
Description
Initial checklist
- I read the support docs
- I read the contributing guide
- I agree to follow the code of conduct
- I searched issues and discussions and couldn’t find anything (or linked relevant results below)
Affected package
unified
Steps to reproduce
I'm building a library that uses unified. So I can't mandate consumers have specific exceptions for unified using cjs dependencies in the dependency graph.
Try vite 6, or rollup with a project that uses unified
(or any other ESM-based packager (esm.sh with no pre-build, for example))
Problem comes from here:
Line 344 in 45d8fa5
import extend from 'extend' |
I did see this issue: #153
But, because I'm a library author, not an app dev, the solutions in that issue are not possible.
Actual behavior
This error:
[!] RollupError: ../../node_modules/.pnpm/[email protected]/node_modules/unified/lib/index.js (350:7): "default" is not exported by "../../node_modules/.pnpm/[email protected]/node_modules/extend/index.js", imported by "../../node_modules/.pnpm/[email protected]/node_modules/unified/lib/index.js".
https://rollupjs.org/troubleshooting/#error-name-is-not-exported-by-module
../../node_modules/.pnpm/[email protected]/node_modules/unified/lib/index.js (350:7)
348:
349: import {bail} from 'bail'
350: import extend from 'extend'
^
351: import {ok as assert} from 'devlop'
352: import isPlainObj from 'is-plain-obj'
Expected behavior
either
extend
gets a default export- we drop the
extend
library 🙈
See: https://rollupjs.org/troubleshooting/#error-name-is-not-exported-by-module
Runtime
node 24
Package manager
rollup 4.x
Operating system
doesn't matter
Build and bundle tools
Rollup
Metadata
Metadata
Assignees
Labels
👎 phase/noPost cannot or will not be acted onPost cannot or will not be acted on👯 no/duplicateDéjà vuDéjà vu