Compiled Javascript tab on documentation examples.
I'm thinking that it might be good to have a way to view compiled Javascript on the documentation examples. It might be helpful to some people, to learn what the syntax is actually doing.
I don’t think many will be interested in this but when browsing the Svelte docs, I found it useful that you could always look at the JS and CSS output tabs. It helps you "demystify all the magic".
- mai 2020 kl. 17:12 skrev Eric Vida [email protected]:
I'm thinking that it might be good to have a way to view compiled Javascript on the documentation examples. It might be helpful to some people, to learn what the syntax is actually doing.
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/imba/imba.io/issues/118, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAHB25H6UHCXG42BLHAMEYLRQQOM5ANCNFSM4M4HY57A.
Had this same idea Eric!! You beat me by two years 😂
I'd like to implement a [compiled] flag for snippets and figure out how to elegantly display the compiled code.
```imba
# [preview=console] [compiled]
console.log "test"
```
I added compiled JS to a new tab manually a few times, but it feels like there must be a way to display the compiled code without making the user click, maybe directly attached to the snippet in a slightly smaller font or something.
@familyfriendlymikey I recall Sindre had a hidden feature somewhere that displayed compiled imba code as a comment in the end of the current file. (vscode ext or scrimba editor, don't remember)