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

context=module must be quoted #804

Closed
mustafa0x opened this issue Nov 19, 2023 · 2 comments
Closed

context=module must be quoted #804

mustafa0x opened this issue Nov 19, 2023 · 2 comments
Labels
bug Something isn't working triage Awaiting triage by a project member

Comments

@mustafa0x
Copy link

mustafa0x commented Nov 19, 2023

Describe the bug

[vite-plugin-svelte] Error while preprocessing ... If the context attribute is supplied, its value must be "module"
 16 |  
 17 |  <script context=module>
               ^
 18 |  import {writable} from 'svelte/store'
 19 |  

Quotes are now required, while they weren't.

System Info

npmPackages:
    @sveltejs/vite-plugin-svelte: ^3.0.0 => 3.0.0 
    svelte: ^4.2.5 => 4.2.5 
    vite: ^5.0.0 => 5.0.0 
@mustafa0x mustafa0x added bug Something isn't working triage Awaiting triage by a project member labels Nov 19, 2023
@mustafa0x
Copy link
Author

<script context=module> is found ~50 times on github.

https://github.com/search?q=language%3Asvelte+%2F%3Cscript+context%3Dmodule%3E%2F&type=code

dummdidumm added a commit to sveltejs/svelte that referenced this issue Nov 20, 2023
dummdidumm added a commit to sveltejs/svelte that referenced this issue Nov 20, 2023
@paulocoghi
Copy link

paulocoghi commented Nov 20, 2023

This issue is now fixed in Svelte v4.2.6, with PR sveltejs/svelte#9551, and it can be closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working triage Awaiting triage by a project member
Projects
None yet
Development

No branches or pull requests

3 participants