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

'Symbol' global object is not defined out of script block #7418

Closed
maxlath opened this issue Apr 4, 2022 · 1 comment
Closed

'Symbol' global object is not defined out of script block #7418

maxlath opened this issue Apr 4, 2022 · 1 comment
Labels
good first issue A small, encapsulated issue, ideal for a new contributor to Svelte to tackle.

Comments

@maxlath
Copy link
Contributor

maxlath commented Apr 4, 2022

Describe the bug

When using Symbol out of a script block, the compiler produces a "'Symbol' is not defined" warning. It works despite the warning though

Reproduction

https://svelte.dev/repl/52dc50b29a784e35bd531e085fbc4dcf?version=3.46.6

Logs

No response

System Info

Svelte 3.46.6

Severity

annoyance

@Conduitry
Copy link
Member

This should just be a matter of adding 'Symbol' to the globals set in https://github.com/sveltejs/svelte/blob/master/src/compiler/utils/names.ts - PRs welcome!

@Conduitry Conduitry added the good first issue A small, encapsulated issue, ideal for a new contributor to Svelte to tackle. label Apr 4, 2022
maxlath added a commit to maxlath/svelte that referenced this issue Apr 4, 2022
maxlath added a commit to maxlath/svelte that referenced this issue Apr 4, 2022
tanhauhau pushed a commit that referenced this issue Apr 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue A small, encapsulated issue, ideal for a new contributor to Svelte to tackle.
Projects
None yet
Development

No branches or pull requests

2 participants