-
-
Notifications
You must be signed in to change notification settings - Fork 232
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
default tree adapter doesn't seem to be exported via export map #619
Comments
I was trying to avoid deep exports, as it is difficult to update relevant paths for CJS and ESM. Ways of accessing the default adapter were discussed in #555. |
we actually want the exported values in this case though, not only the types. as we want to make use of the default tree adapter's functions. so im not sure how else we can get that other than exposing the default tree adapter module. do you have another way in mind? |
@fb55 happy to have a go at doing a PR for this but im not 100% sure what the right export map is... if i try something like: "exports": {
".": {
"import": "./dist/index.js",
"require": "./dist/cjs/index.js"
},
"./dist/tree-adapters/default.js": {
"import": "./dist/tree-adapters/default.js"
}
}, we're also forced to add anything the default tree adapter depends on (e.g. if you can help me out knowing what the right solution is here i can try write it up |
Why not export it from the main module? |
@wooorm that would make life a lot easier! ill open a PR, no clue why i didn't consider that :D |
This is fixed by #631 i think, the rest of the symbols were already exported top level |
trying to use it in the p5 tools package:
trying to import
parse5/dist/tree-adapters/default.js
.is it because we have
./dist/index.js
in our export map but nothing else? so we needdist/tree-adapters/*
too maybe?cc @fb55
The text was updated successfully, but these errors were encountered: