From: Michael Neumann Date: 2007-01-16T20:38:02+09:00 Subject: Re: [ANN] RubyJS - Convert Ruby to Javascript Une B�vue wrote: > Michael Neumann wrote: > >> > I got the same error with that writing : >> > ../bin/../lib/rubyjs/method_generator.rb:1040:in `method_missing': Not >> > implemented (RuntimeError) >> > [...] >> > from ../bin/rubyjs_gen:82 >> >> Ah, that seems to be a different problem. Can I see your "Ruby/JS" code? >> You probably use a Ruby construct which is not yet supported ("case" for >> example). > > not at all, as i said, i've just simplified your HelloWorld class but > add the `document.getEllementById...` and change yours p(something) to > self.puts(something) here it is : > > essai.rb> Change #{ ... } to #< ... > def puts(str) `document.getElementById("STDOUT")['innerHTML'] = document.getElementById("STDOUT")['innerHTML'] + "#\n"` end And if you move "puts" into module Kernel, then you can also use the "p" method, which is equivalent to puts(obj.inspect). Regards, Michael