-
Notifications
You must be signed in to change notification settings - Fork 43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Convert CoffeeScript to ES6 please #34
Comments
i'll do this eventually |
updates? |
This feels like a step backwards to me. ES6 means transpilers or polyfills become required for broader browser coverage. Right now you could start using this with an inline |
This does a pretty good job of auto conversion, just needs some cleaning up after: http://decaffeinate-project.org/ |
@cferdinandi You are compiling either way. You might as well use babel instead. The broadest skill all web developer have in common is plain javascript it is here to stay. And more will contribute to the code. coffeescript will always be one step behind javascript. you couldn't use async await when it came out. you had to wait for CS to adopt to it. |
I'm not advocating coffee script. I'm a vanilla JS evangelist. I'm simply arguing for ES5 until ES6 has broader support. What advantage does ES6 bring to the script? |
ES6 is fully supported in all major browsers and in node.js. Many of the language features I personally used to use CoffeeScript for are now supported natively in ES6 (arrow functions and classes are the two major ones). ES6 has way better editing and debugging experience in most major editors than CoffeeScript. More developers know JavaScript than CoffeeScript, hence a lower maintenance burden. |
Afterthought: I realize the responses to my comments are driven by this being an issue about CoffeeScript. When I first read it, I missed the part about CoffeeScript and assumed the ask what just to update from ES5 to ES6. @chucksellick This makes perfect sense:
tldr: I'm a dumbass, missed the thing about CoffeeScript, and agree 100%, so long as the end product is converted to ES5. |
The usual strategy is to distribute the npm package with multiple ES5 transpiled versions of the library (different versions to target different module loaders; CommonJS, UMD, etc), as well as the raw ES6 source. This way the environment can decide which version is most appropriate, with ES5 being the default. ES6 can be run in environments where it's supported natively (e.g. modern node) and bundlers can also use ES6 as they might only transpile a subset of ES6 features if they are targeting newer browsers. What real advantages does ES6 bring to the table over ES5? Cleaner and therefore more maintainable source code is the only really tangible thing I can actually claim! |
i agree. i'll do the conversion to ES6 before the end of february since this package is seeing some use and several people want this. i've been using ES6 and babel extensively over the last couple of years so this shouldn't be a big deal. when i started work on this package back in 2012 there were good reasons to use coffeescript. today there aren't any imo. continuing to use coffee makes it harder for others to contribute.
100% agree. thanks for the links |
Any news on this? |
No description provided.
The text was updated successfully, but these errors were encountered: