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

playground freezes browser #317

Closed
2 tasks done
DetachHead opened this issue Dec 12, 2022 · 6 comments · Fixed by #322
Closed
2 tasks done

playground freezes browser #317

DetachHead opened this issue Dec 12, 2022 · 6 comments · Fixed by #322

Comments

@DetachHead
Copy link
Contributor

DetachHead commented Dec 12, 2022

Before You File a Bug Report Please Confirm You Have Done The Following...

  • I have tried restarting my IDE and the issue persists.
  • I have updated to the latest version of the packages.

What version of ESLint are you using?

n/a

What version of eslint-plugin-svelte are you using?

n/a

What did you do?

navigate to https://ota-meshi.github.io/eslint-plugin-svelte/playground/#eJyrrgUAAXUA+Q==

What did you expect to happen?

it works

What actually happened?

image
image

Link to GitHub Repo with Minimal Reproducible Example

n/a

Additional comments

tested on chrome and firefox on 3 different devices

@ota-meshi
Copy link
Member

Thanks for letting me know. I will check that.

@ota-meshi
Copy link
Member

Hmm. It looks like the postcss tokenizer source code is broken by minify. Broken postcss tokenizer loops infinitely.

@ota-meshi
Copy link
Member

Hmm. Even with minify turned off, the necessary source code is missing in the build. I still don't know the cause of it.

Original:

          RE_WORD_END.lastIndex = pos + 1
          RE_WORD_END.test(css)
          if (RE_WORD_END.lastIndex === 0) {
            next = css.length - 1
          } else {
            next = RE_WORD_END.lastIndex - 2
          }

Output:

          RE_WORD_END.lastIndex = pos + 1;
          if (RE_WORD_END.lastIndex === 0) {
            next = css.length - 1;
          } else {
            next = RE_WORD_END.lastIndex - 2;
          }

@ota-meshi
Copy link
Member

I still don't know the cause, so I opened an issue on vite's repository.
vitejs/vite#11330

@DetachHead
Copy link
Contributor Author

if it helps narrow it down, i'm pretty sure it was working properly until a few days ago

@ota-meshi
Copy link
Member

I suspect that a major version upgrade of vite v4 or rollup v3 is the cause of the problem, but I'm not sure how to confirm that at the moment 😅

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

Successfully merging a pull request may close this issue.

2 participants