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

The dead loop of Vue SFC Playground #11423

Closed
dxlyf opened this issue Jul 23, 2024 · 2 comments
Closed

The dead loop of Vue SFC Playground #11423

dxlyf opened this issue Jul 23, 2024 · 2 comments
Labels
🍰 p2-nice-to-have Priority 2: this is not breaking anything but nice to have it addressed. scope: playground

Comments

@dxlyf
Copy link

dxlyf commented Jul 23, 2024

Vue version

3.4.33

Link to minimal reproduction

https://play.vuejs.org/#eNp9kUFPAjEQhf/K2MtCgixET7CQqCFRD2rUxEsvZJldit22abtIsul/d9oNyMFw67z3ZvpNpmN3xoz3LbIZK1xphfHg0LdmyZVojLYeOrBYQYDK6gYyimZccVVq5Tw0roZF9AfZI0qp4UtbubnKhlxV2g4kehCLyVwU08l82AWuirz/hMZT4bExcu2RKoBiO112XRoZQpFTlVShTOthf93oDcoFZ+RzBjmZRX7Wz0bMO4KqRD3eOa1ony72c1bqxgiJ9tV4QdCczSA50VsT889z0rxtcXTUyy2W3//oO3eIGmdvFh3aPXJ28vza1uh7e/Xxggd6n0yibyWlL5jv6LRsI2Mfu2/VhrDPcon2KV1FqPrTrQ4elTsuFUFjMqQ8Z3Sphwur/+HejG9TH1eBhV+Wuq5G

Steps to reproduce

for(let i=0;i<10;)
or
for(let i=0;i<10;){
if(condition==2){
i+=2
}else{
i++;
}
}

What is expected?

Can we add a preview to prevent the code from running in real-time? Or add a manual refresh preview, or solve this problem through technical means

What is actually happening?

I really enjoy doing some small examples in Vue SFC Playground. But I found that when writing some loop statements such as for while code, it can easily cause the webpage to freeze and freeze.

System Info

No response

Any additional comments?

No response

@yyx990803 yyx990803 added 🍰 p2-nice-to-have Priority 2: this is not breaking anything but nice to have it addressed. scope: playground labels Jul 24, 2024
@qtencent7
Copy link

这个东西,我觉得无解吧,我试了,就算不是vue里面,像你那样写,也会出现这种卡死

@yyx990803
Copy link
Member

closed via #11428

@github-actions github-actions bot locked and limited conversation to collaborators Sep 26, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
🍰 p2-nice-to-have Priority 2: this is not breaking anything but nice to have it addressed. scope: playground
Projects
None yet
Development

No branches or pull requests

3 participants