pixelkind / p5canvas

An interactive preview for writing p5js code in Visual Studio Code
https://marketplace.visualstudio.com/items?itemName=garrit.p5canvas
Other
39 stars 4 forks source link

Auto-reload handling of loops #46

Open ccoenen opened 3 years ago

ccoenen commented 3 years ago

while adding a regular for loop, in VS Code at one point one will have an infinite loop in their editor by the nature of its autocompletion. for () in the editor will then directly be executed.

This way, whenever a loop is added, the preview window will get stuck in an infinite loop, and currently this means one must close and reopen that.

We could try to detect an endless loop while running, or maybe there's a jshint-rule for that?