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

vitest clobbers playwright in a fresh SvelteKit installation. #1520

Closed
6 tasks done
kyllerss opened this issue Jun 21, 2022 · 3 comments
Closed
6 tasks done

vitest clobbers playwright in a fresh SvelteKit installation. #1520

kyllerss opened this issue Jun 21, 2022 · 3 comments
Labels

Comments

@kyllerss
Copy link

Describe the bug

Installing vitest in a fresh SvelteKit project causes playwright tests to fail with a runtime error. The project's README.md provides the full error report, but a sample of the error message is as follows:

[WebServer] [vite-plugin-svelte] /home/my_home/vitest-playwright-bug/.svelte-kit/runtime/components/layout.svelte:15:1 The keyword 'let' is reserved
file: /home/my_home/vitest-playwright-bug/.svelte-kit/runtime/components/layout.svelte:15:1
 13 |  
 14 |  function create_fragment(ctx) {
 15 |    let current;
         ^
 16 |    const default_slot_template = /*#slots*/ ctx[1].default;
 17 |    const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[0], null);
[WebServer] > /home/my_home/vitest-playwright-bug/.svelte-kit/runtime/components/layout.svelte:15:1 The keyword 'let' is reserved
[WebServer] 13: 
14: function create_fragment(ctx) {
15:   let current;
      ^
16:   const default_slot_template = /*#slots*/ ctx[1].default;
17:   const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[0], null);
    at error (file:///home/my_home/vitest-playwright-bug/node_modules/svelte/compiler.mjs:17716:19)
...

Reproduction

I have created a public repo that illustrates the problem:

https://github.com/kyllerss/vitest-playwright-bug

The commit history is clean to illustrate where things break.

System Info

Fresh SvelteKit installation w/ Typescript + Playwright.

Used Package Manager

npm

Validations

@sheremet-va
Copy link
Member

Please, follow SvelteKit support here: sveltejs/kit#5094

@benmccann
Copy link
Contributor

@sveltejs/kit/experimental/vite has been released in @sveltejs/kit version 1.0.0-next.353. Feedback welcome in sveltejs/kit#5184

@kyllerss
Copy link
Author

kyllerss commented Jul 8, 2022

The issue has shifted now. I will file a separate bug report as I think the issue now lies elsewhere. Considering this closed.

@kyllerss kyllerss closed this as completed Jul 8, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Jun 16, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants