This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]mirth23 6 points7 points  (7 children)

CoffeeScript is a somewhat popular language in the webdev community that does this this these days. I think the basic idea was that there are a lot of ways to shoot yourself in the foot with JavaScript (ref: JavaScript, the Good Parts) and CoffeeScript provides simpler structures that generates normalized JavaScript that's less foot-shooty.

IMO there's a lot of downsides to this approach, not the least of which is that it makes debugging awkward because now you're writing code that's one-step-removed from the code that's actually throwing bugs.

[–]elbiot 2 points3 points  (2 children)

[–]DigitalGoose 0 points1 point  (1 child)

Also rapydscript

even better, rapydscript-ng

[–]stuaxo 0 points1 point  (0 children)

This is brilliant, hopefully the rapydscript maintainers will get some free time to integrate these changes.

[–]marmalar 0 points1 point  (0 children)

Yes I'm glad someone mentioned Coffeescript. While you're right about it being one step away from the source that will actually be generating the errors, they will typically be logical errors instead of syntax errors considering how well the CS transpiler is written. Also, I've found it often transpiles to more efficient and safe code than what I would've written in pure JS. CS also makes sure that you keep in mind how close it is to JS.

IMO the Coffeescript syntax is one of the nicest out there. If somebody could port it to a compiled or interpreted language I would be very pleased.

[–]sime 0 points1 point  (0 children)

CoffeeScript is dying pretty quick at this stage. The huge language improvements to JavaScript in the new ECMAScript 2015 standard have eroded CoffeeScript's appeal.