RubyJS: A JavaScript standard library based on the Ruby core-lib
31–38 of 38 posts
Re: RubyJS: A JavaScript standard library based on the Ruby core-lib
#32Hell, I could even use JQuery for a lot of this stuff, but I really like ruby standard library and it's cleaness.
Re: RubyJS: A JavaScript standard library based on the Ruby core-lib
#33Re: RubyJS: A JavaScript standard library based on the Ruby core-lib
#34If it is the case, i expect the performance to be pretty abysmal. Do you have some data on that ?
Re: RubyJS: A JavaScript standard library based on the Ruby core-lib
#35I did a quick check of the implementation, am I wrong in thinking every primitive type is boxed ? If it is the case, i expect the performance to be pretty abysmal. Do you have some data on that ?
Re: RubyJS: A JavaScript standard library based on the Ruby core-lib
#36Re: RubyJS: A JavaScript standard library based on the Ruby core-lib
#37I did a quick check of the implementation, am I wrong in thinking every primitive type is boxed ? If it is the case, i expect the performance to be pretty abysmal. Do you have some data on that ?
Yes. Primitives are boxed. However method arguments are only boxed when needed, which makes it as fast as normal. In the methods internally are all using JS primitives (there are some left-overs where that's not the case yet). Wrapper objects are similarly fast as extending native JS types.
Re: RubyJS: A JavaScript standard library based on the Ruby core-lib
#38Earlier quoted context omitted.
I don't really see why RubyJS would be better than PHP.js. And I'm definitely not saying that PHP.js should be used. [edit] To be more specific, I really don't see the point of using a third-party library when the native methods are available. IMHO, if you choose a language, you should stick with it.
RubyJS creator here. I was just missing so many (native) methods in javascript. i liked the standard library of javascript and there is an extensive public ruby testsuite that i could use to test my implementation against. Plus i liked the idea of taking something that already works elsewhere and translate it JS, instead of coming up with my own API. IMO it's the same as using underscore/lodash, stringjs, etc, just a…