Skip to content
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

svelte 5 support #115

Open
niemyjski opened this issue Dec 15, 2023 · 8 comments
Open

svelte 5 support #115

niemyjski opened this issue Dec 15, 2023 · 8 comments

Comments

@niemyjski
Copy link

niemyjski commented Dec 15, 2023

If you create a new svelte 5 starter app (out of the box supported with create app..) and add svelte legos, it completely breaks the site. I'm really only using the media queries and clipboard.

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "get_current_component"

    node_modules/svelte-legos/dist/shared/index.js:1:9:
      1 │ import { get_current_component, onDestroy } from "svelte/internal";
        ╵          ~~~~~~~~~~~~~~~~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "is_client"

    node_modules/svelte-legos/dist/shared/index.js:3:9:
      3 │ import { is_client } from "svelte/internal";
        ╵          ~~~~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "listen"

    node_modules/svelte-legos/dist/stores/mouseStore/index.js:3:9:
      3 │ import { listen } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "is_client"

    node_modules/svelte-legos/dist/stores/pointerStore/index.js:2:9:
      2 │ import { is_client, listen } from "svelte/internal";
        ╵          ~~~~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "listen"

    node_modules/svelte-legos/dist/stores/pointerStore/index.js:2:20:
      2 │ import { is_client, listen } from "svelte/internal";
        ╵                     ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "noop"

    node_modules/svelte-legos/dist/stores/timeoutStore/index.js:1:9:
      1 │ import { noop } from "svelte/internal";
        ╵          ~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "listen"

    node_modules/svelte-legos/dist/stores/windowScrollStore/index.js:3:9:
      3 │ import { listen } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "listen"

    node_modules/svelte-legos/dist/stores/windowSizeStore/index.js:3:9:
      3 │ import { listen } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "append"

    node_modules/svelte-legos/dist/stores/messagesStore/Message.js:1:9:
      1 │ import { append, attr, element } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "append"

    node_modules/svelte-legos/dist/stores/messagesStore/MessageManager.js:1:9:
      1 │ import { append, attr, element } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "listen"

    node_modules/svelte-legos/dist/actions/clickOutsideAction/index.js:1:9:
      1 │ import { listen } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "append"

    node_modules/svelte-legos/dist/actions/textareaAutosizeAction/core.js:1:9:
      1 │ import { append, attr, element } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "append"

    node_modules/svelte-legos/dist/actions/tooltipAction/index.js:2:9:
      2 │ import { append, attr, element, listen } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "listen"

    node_modules/svelte-legos/dist/actions/tooltipAction/index.js:2:32:
      2 │ import { append, attr, element, listen } from "svelte/internal";
        ╵                                 ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "append"

    node_modules/svelte-legos/dist/actions/sortableTableAction/index.js:1:9:
      1 │ import { append } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "append"

    node_modules/svelte-legos/dist/actions/resizableAction/index.js:1:9:
      1 │ import { append, attr, element } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "append"

    node_modules/svelte-legos/dist/actions/notifyAction/Notification.js:1:9:
      1 │ import { append, element, attr } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "append"

    node_modules/svelte-legos/dist/actions/notifyAction/NotificationManager.js:1:9:
      1 │ import { append, attr, element } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "append"

    node_modules/svelte-legos/dist/actions/loadingAction/Loader.js:1:9:
      1 │ import { append, attr, element } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "append"

    node_modules/svelte-legos/dist/actions/alertAction/Alert.js:1:18:
      1 │ import { element, append, attr } from "svelte/internal";
        ╵                   ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "append"

    node_modules/svelte-legos/dist/actions/clickToCopyAction/Clipboard.js:1:9:
      1 │ import { append, element } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "listen"

    node_modules/svelte-legos/dist/actions/infiniteScrollAction/index.js:1:9:
      1 │ import { listen } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "listen"

    node_modules/svelte-legos/dist/utilities/battery/index.js:4:9:
      4 │ import { listen } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "listen"

    node_modules/svelte-legos/dist/utilities/preferredLanguages/index.js:3:9:
      3 │ import { listen } from "svelte/internal";
        ╵          ~~~~~~

X [ERROR] No matching export in "node_modules/svelte/src/internal/index.js" for import "listen"

    node_modules/svelte-legos/dist/utilities/screenOrientation/index.js:3:9:
      3 │ import { listen } from "svelte/internal";
        ╵          ~~~~~~

7:06:06 AM [vite] error while updating dependencies:
Error: Build failed with 25 errors:
node_modules/svelte-legos/dist/actions/alertAction/Alert.js:1:18: ERROR: No matching export in "node_modules/svelte/src/internal/index.js" for import "append"
node_modules/svelte-legos/dist/actions/clickOutsideAction/index.js:1:9: ERROR: No matching export in "node_modules/svelte/src/internal/index.js" for import "listen"
node_modules/svelte-legos/dist/actions/clickToCopyAction/Clipboard.js:1:9: ERROR: No matching export in "node_modules/svelte/src/internal/index.js" for import "append"
node_modules/svelte-legos/dist/actions/infiniteScrollAction/index.js:1:9: ERROR: No matching export in "node_modules/svelte/src/internal/index.js" for import "listen"
node_modules/svelte-legos/dist/actions/loadingAction/Loader.js:1:9: ERROR: No matching export in "node_modules/svelte/src/internal/index.js" for import "append"
...
    at failureErrorWithLog (D:\ClientApp\node_modules\esbuild\lib\main.js:1650:15)
    at D:\ClientApp\node_modules\esbuild\lib\main.js:1058:25
    at D:\ClientApp\node_modules\esbuild\lib\main.js:1526:9
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    ```
@niemyjski
Copy link
Author

@ankurrsinghal I haven't had any time to look into this, have you had any chance to try out svelte 5, release is coming really soon

@urjeetpatel
Copy link

it looks like reverting #80 should help resolve a whole bunch of issues since in Svelte 5 use of internal functions is now an error [sveltejs/svelte/pull/11632]

@jdvlpr
Copy link

jdvlpr commented Oct 23, 2024

Svelte 5 is here! This package breaks my app since it still imports from svelte/internal. If it can be updated that would be great.

@IsraPerez98
Copy link

Pull request #124 just got merged, that should fix the main issue, can anyone confirm by building from source?

@jalavosus
Copy link
Contributor

@IsraPerez98 I can't get it to build from source, it would be really great if @ankurrsinghal could chime in here. I wouldn't mind opening a PR to work on this, I just don't want to duplicate effort.

@bourhaouta
Copy link

Pull request #124 just got merged, that should fix the main issue, can anyone confirm by building from source?

looks like we need an npm release for that merge

@jalavosus
Copy link
Contributor

Waiting for some kind of fix was taking too long, so I did it myself with #125.

@jalavosus
Copy link
Contributor

It looks like this has been merged into master, it just needs an NPM update (@ankurrsinghal, when you can, this would be most welcome. Thanks!)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants