3 ms·
To be fair you can write vim plugins in python, and a fair number of people do. It's also, I'd argue, a fail from the Atom guys to make their plugins run in co
by shadowmint 12y ago
To be fair you can write vim plugins in python, and a fair number of people do.
It's also, I'd argue, a fail from the Atom guys to make their plugins run in coffee script natively, rather than allowing people the choice of compile-to-javascript/native javascript to write plugins in (this has definitely hurt adoption for the creation of plugins that do more than trivial things or syntax highlighting).
The thing about atom that is compelling for me is apm (the command line atom package manager); its really very good.
(Yes, I know you can write 'pure javascript' atom plugins, but its complex and it's clunky; you have to manually implement the coffee script inheritance semantics. Fail.)
- adrusi 12y ago"Coffeescript inheritance semantics" aren't anything special in javascript. If the editor was written in javascript syntax and still chose to make use of inheritance in its design, extensions would look the same. This works just fine, and it can't get much more javascripty: ExtensionComponent.prototype = Object.create(Component.prototype); function ExtensionComponent() { Component.call(this); } ExtensionComponent.prototype.doSomething = function () { // ... };
- shadowmint 12y agoHave you actually tried it? Seems like the people who actually have found it a little more complicated than that (see http://discuss.atom.io/t/coffeescript---extends-vs-util-inherits-inheritance-in-js/2536 http://discuss.atom.io/t/coffeescript---extends-vs-util-inhe...). To quote the post: The difference is important. CS copies functions from parent to child on top of setting the prototype while the std library just does the latter. Inheriting from require("atom").View breaks without doing this manually (which isn't obvious at all). If this is not being done for performance, it should be documented; otherwise, those methods should be moved to the prototype.