emruby icon indicating copy to clipboard operation
emruby copied to clipboard

[Documentation / Tutorial] Let users run irb emruby on their webpages?

Open rubyFeedback opened this issue 2 years ago • 0 comments

Hey there mame,

This is mostly a suggestion, but if you consider it useful then perhaps the main README could mention this.

You provide a link to a demo here:

https://mame.github.io/emruby/

This works too.

(One thing confuses me: the "downloading data" part. But this is an aside, I just was not expecting that display after clicking on "run".)

If I can see it correctly then we kind of have irb there for the www, yes? A bit similar I suppose how _why had this a long time ago (before BasicObject was added to core; I think it was added after _why proposed it, matz agreed. At the least I think this was the case, and _why had some projects back then, one of which was that irb-thingy in the browser.)

My idea or use case now would be that, for instance, someone using rails or sinatra, may want to embed a little irb like this too, for use on the www. Ideally with some customization in place (e. g. how much control; would be pretty cool if customization would be possible to even allow people to remote-control their computer at home via this! :D Though the default of course to be restricted in permission.)

Anyway - the TL;DR of this here is mostly to think whether emruby could be used for people to embed irb on the www on a homepage. For instance, thinking of a sinatra application, I could see to simply and easily add a route called "/irb" and let people work on irb there. Or perhaps even add an interactive tutorial too.

I don't know whether that includes your concerns of a valid use case for emruby or whether emruby is just meant as a demo-application and a "proof of concept". Which is fine, but I am more wondering for "irb on the www for everyone". Including hobbyists. :D

Please feel free to close/ignore the issue request here at your own choosing, this is not meant to add more workload to your schedule but more as a "possibly useful idea".

rubyFeedback avatar Feb 27 '22 17:02 rubyFeedback