tinymce / tinymce-svelte

Svelte wrapper
MIT License
23 stars 6 forks source link

Add missing exports conditions #50

Closed laxadev closed 2 months ago

laxadev commented 8 months ago

You can find more information about this here https://github.com/sveltejs/vite-plugin-svelte/blob/main/docs/faq.md#missing-exports-condition

ptrxyz commented 7 months ago

With latest versions of Svelte, this is required and throws nasty warnings all day long.

The fix is super simple, simply add the exports object to the package.json and it's all good:

...
"svelte": "dist/index.js",
  "exports": {
    ".": {
      "types": "./dist/ts/index.d.ts",
      "svelte": "./dist/index.js"
    }
  },
...

edit: added types

ptrxyz commented 7 months ago

Added PR: #52