Open peterjoel opened 6 years ago
require that there is a global fn main(input: String)
diagnostic for telling the user about how the main() should look
See also #323 which has the idea of "templates"
Hi, I am interested to implement this feature and start to work on it. This feature could be used in mdBook to write the interactive tutorial for wasm-bindgen, yew and seed framework.
Even a very minimalistic js-fiddle like setup that let's us call functions of the wasm with javascript would be huge.
Update the latest work so far. I already tested on mdBook and rust-playground will work on it too!
It would be cool to be able to write Rust code for a WASM target and then execute it immediately within the web browser. A simple terminal could be made which supports calling methods and viewing the output.
Some background from Lukas Kalbertodt: https://chat.stackoverflow.com/transcript/message/43471308#43471308