Last active
December 16, 2015 18:08
-
-
Save joshnuss/5475085 to your computer and use it in GitHub Desktop.
jQuery over ruby in the browser. with mruby and asm.js. Paste code below into http://qiezi.me/projects/mruby-web-irb/mruby.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# paste me into http://qiezi.me/projects/mruby-web-irb/mruby.html | |
MrubyJs.window.instance_eval do | |
if confirm("continue?") | |
console.log "you chose continue" | |
food = prompt("What's your favourite food?") | |
alert "Really?? #{food}?\nThat's gross." | |
jQuery('body').prepend("<h1>Likes #{food}</h1>") | |
else | |
console.log "you chose not to coninue" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment