This (super preliminary) draft change adds IntelliSense/autocomplete to the editor!
To best handle this change, I switched the editor from CodeMirror to Monaco (the base of VS Code), since Monaco handles autocomplete much better (and by default!). This required a lot of other changes---updating the Webpack versions significantly, etc.
There's a ton of work left--- the editor is mis-sized (fixed!) and does not support undo/redo yet (supports undo now!). See the TODOs!
This (super preliminary) draft change adds IntelliSense/autocomplete to the editor!
To best handle this change, I switched the editor from CodeMirror to Monaco (the base of VS Code), since Monaco handles autocomplete much better (and by default!). This required a lot of other changes---updating the Webpack versions significantly, etc.
There's a ton of work left---
the editor is mis-sized(fixed!)and does not support undo/redo yet(supports undo now!). See the TODOs!But wow, it's so cool!
Example
You can mess with it at https://ben.stolovitz.com/p5.js-widget/!
Previous screenshots
Before style changes:Notes
@types/p5
since that is used for the auto-complete (yeah, ew).index.html
etc tostatic/
.TODO