-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Find a way to detect endless loops #50
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
Find a way to detect endless loops #50
Comments
Ah interesting! Just checked loop-protect and they've done a really great job, cool solution. Would be cool if we had something similar but then that it alters the AST, like a babel plugin. This is what I quickly found: https://www.npmjs.com/package/babel-plugin-looptar but I sploke with repl.it also and they built something for babel to solve it. |
Just found this https://repl.it/site/blog/infinite-loops, interesting as they are using a babel plugin as well. |
This is still a bug in the React TypeScript starter. To freeze your tab, open https://codesandbox.io/s/react-ts and type |
When a sandbox has an endless loop it won't stop executing until the tab kills the editor. This means that users can lose their sandbox.
Maybe there is a way to limit execution time of a sandbox, or maybe we should add a 'Run' button when you're editing your own sandbox. Would love to hear some thoughts.
The text was updated successfully, but these errors were encountered: