Add foreign module and HTML editor
maybe with tabs
:+1: Can we think of a nice way of having this work in combination with Gists?
Possibly make both sources have their own gists and have the PureScript one reference the other by a comment on the first line (not necessarily shown in the editor).
-- foreign GIST_ID_HERE
module ...
I tried creating a gist with a Main.purs and Main.js hoping that would work.
It would be great if it did, even if it's not the most ideal way to support foreign modules.
The big problem here is security. We don't want unverified foreign code being eval'd on user's machines without their say so.
I figured that would be a big factor.
What we could do is to have compile.purescript.org serve the entire HTML page into the iframe. Then the same origin policy would solve things for us. We could even load more packages this way.