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

enabling runes globally doesn't work #9432

Closed
proof-llc opened this issue Nov 13, 2023 · 3 comments
Closed

enabling runes globally doesn't work #9432

proof-llc opened this issue Nov 13, 2023 · 3 comments

Comments

@proof-llc
Copy link

Describe the bug

In svelte.config.js we want to be able to enable runes globally. At present it doesn't work.

Reproduction

  1. pnpm create svelte@latest my-app2
  • Skeleton project
  • Typescript
  • ESLint
  • Prettier
  • Svelte 5 beta
  1. cd my-app2
  2. pnpm install
  3. set runes: true in svelte.config.js
  4. pnpm run dev -- --open

Logs

CompileError: Cannot use `export let` in runes mode — use $props instead
    at error (file:///private/tmp/my-app2/node_modules/.pnpm/svelte@5.0.0-next.2/node_modules/svelte/src/compiler/errors.js:568:8)
    at ExportNamedDeclaration (file:///private/tmp/my-app2/node_modules/.pnpm/svelte@5.0.0-next.2/node_modules/svelte/src/compiler/phases/2-analyze/validation.js:628:3)
    at go (file:///private/tmp/my-app2/node_modules/.pnpm/svelte@5.0.0-next.2/node_modules/svelte/src/compiler/phases/visitors.js:49:5)
    at visitor (file:///private/tmp/my-app2/node_modules/.pnpm/svelte@5.0.0-next.2/node_modules/svelte/src/compiler/phases/visitors.js:64:4)
    at go (file:///private/tmp/my-app2/node_modules/.pnpm/svelte@5.0.0-next.2/node_modules/svelte/src/compiler/phases/visitors.js:49:5)
    at visitor (file:///private/tmp/my-app2/node_modules/.pnpm/svelte@5.0.0-next.2/node_modules/svelte/src/compiler/phases/visitors.js:64:4)
    at Object.next (file:///private/tmp/my-app2/node_modules/.pnpm/zimmerframe@1.1.0/node_modules/zimmerframe/src/walk.js:106:21)
    at go (file:///private/tmp/my-app2/node_modules/.pnpm/svelte@5.0.0-next.2/node_modules/svelte/src/compiler/phases/visitors.js:45:29)
    at next (file:///private/tmp/my-app2/node_modules/.pnpm/svelte@5.0.0-next.2/node_modules/svelte/src/compiler/phases/visitors.js:55:7)
    at _ (file:///private/tmp/my-app2/node_modules/.pnpm/svelte@5.0.0-next.2/node_modules/svelte/src/compiler/phases/scope.js:666:4)

System Info

System:
    OS: macOS 14.1
    CPU: [REDACTED]
    Memory: [REDACTED]
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 21.1.0 - /usr/local/bin/node
    Yarn: 1.22.18 - /opt/homebrew/bin/yarn
    npm: 9.6.7 - /opt/homebrew/bin/npm
    pnpm: 8.9.2 - /usr/local/bin/pnpm
    bun: 1.0.2 - ~/.bun/bin/bun
  Browsers:
    Chrome: 119.0.6045.123
    Chrome Canary: 120.0.6089.3
    Safari: 17.1
    Safari Technology Preview: 17.4
  npmPackages:
    svelte: ^5.0.0-next.1 => 5.0.0-next.2

Severity

blocking an upgrade

@proof-llc
Copy link
Author

updated to 5.0.0-next.2 - same error

@brunnerh
Copy link
Member

Looks like a duplicate of sveltejs/kit/issues/11022.

@Conduitry
Copy link
Member

Yup. Duplicate of sveltejs/kit#11022. Will be resolved by Kit adjusting its generated code according to whether it detects you're using Svelte 5.

@Conduitry Conduitry closed this as not planned Won't fix, can't repro, duplicate, stale Nov 13, 2023
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

3 participants