|
|
|
|
|
by sic1
4984 days ago
|
|
While we are posting contrived examples. What was ever wrong with this? var Foo = function() {};
Foo.prototype.jump = function() {
return "I jump."
};
Foo.prototype.run = function() {
return "I run."
};
var mario = new Foo();
mario.run();
mario.jump();
I can't imagine that opal code running nearly as fast as javascript. And if we are waving around compiled js - coffeescript does a much better job of being readable. You just black-boxed the whole thing. I like to know what is happening with my js.Cool for the rubyist in you i guess. I just kinda go o_0 |
|