BUG: Missing type declaration from exports in package.json
Question
GrapesJS version
- I confirm to use the latest version of GrapesJS
What browser are you using?
chrome
Reproducible demo link
https://github.com/padcom/grapesjs-import-error
Describe the bug
0.21.6 changed the way things are exported and now VSCode doesn't see type declarations:
It happens when TypeScript uses:
"compilerOptions": {
"module": "ESNext",
"moduleResolution": "bundler",
"strict": true
}
which is the default setting in @vue/tsconfig/tsconfig.json used in all Vue.js applications and also it is the default in all vite.js templates.
That's how it should look in https://github.com/GrapesJS/grapesjs/blob/dev/package.json#L12:
"exports": {
".": {
"import": "./dist/grapes.mjs",
"require": "./dist/grapes.min.js",
"types": "./dist/index.d.ts"
},
"./*": "./*"
},
Code of Conduct
- I agree to follow this project's Code of Conduct
Answers (1)
Related Questions and Answers
Continue research with similar issue discussions.
Issue #5385
BUG: getDirtyCount() non deterministic after load
GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome Reproducible demo link https://gith...
Issue #5373
BUG: `getDirtyCount()` returns `1` after loading
GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome latest Reproducible demo link https...
Issue #3778
BUG: Select options are not displaying - new anomaly
GrapesJS version[X] I confirm to use the latest version of GrapesJSWhat browser are you using? ChromeReproducible demo link https://github....
Issue #6024
BUG: unable to hide rte for some particular component type
GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome Reproducible demo link https://code...
Paid Plugins That Match This Issue
Curated by issue keywords and label relevance to help you ship faster.
Loading paid plugin recommendations...
Browse Plugin Categories
Jump directly to plugin category pages on the marketplace.