Coffee core
-
I think it's a fair thing to require gulp or grunt to build the product, it's quite common. The problem I see is that this would go into core and I would love to keep that plain JavaScript. Personally I have played with the thought of adding some thing, but that would most likely be plugins. If core has multiple languages or a preprocessor version and a plain version, it could basically scare people off.
When creating a plugin I would both deliver source and a compiled version, so 2. would be what I would do (again, for a plugin, not core).
I don't use coffee script, but I blogged about it on jsnews, so I kinda know of it and have played with it.
-
@frissdiegurke While I'm all for coffeescript in plugins (and even dabbled in it at times with my really bad and untested PRs to emoji-extended!), I'm going to have to step in and say that we can't allow any coffeescript into the core code.
The main stopping points are that:
- An extra dependency is added (even if only for development), and a precompile step is required.
- We are afraid that a coffeescript heavy project will discourage developers from contributing back
- Coffeescript->JS is a one-way compilation, and updates to the javascript files don't end up propagating upwards to the source .coffee files
So while I'm definitely looking to merge in the settings PR, it would have to be javascript only, so the bus factor can be higher than 1!
-
You guys should take a look at TypeScript
-
Guys, do we really need a higher level form of "code" than javascript?
-
@HolyPhoenix there are actually a lot of arguments to do so. One would be because JS isn't statically typed, requiring all the
parseInt
's there currently are.(I kinda stole this argument from @Almost)
-
It's a difficult decision (whether or not to jump to coffee), and right now, I'm not even sure it's the right one. It's a bit hypocritical of me to say "Coffeescript is too new", since NodeBB is built on Node.js, which didn't even exist a decade ago...
-
My two cents here,
Plain JavaScript can be coded by some kid out of highschool with no background in anything to do with computers (that was me once a upon a time :p). I just feel that coffeescript (or typescript) increases the barrier of entry for those kind of guys.
The other thing is that it doesn't make sense for 5% of the core to be of one language and the other 95% to be something else. Unless you were to rewrite the whole codebase (then I guess you can fire us too, give us royalties plx :p) but that seems like an undertaking and a half yeah?
Anyways you're taking a lot of flak but I'm really glad to have you onboard, hope our statements don't discourage you from working with our community. There's quite a few people downloading your coffeescript stuff on npm and so that means there's a demand for it. So keep it up!
-
@psychobunny said:
There's quite a few people downloading your coffeescript stuff on npm and so that means there's a demand for it. So keep it up!
I agree, as long as the functionality is there and it's not broken, it can be written in
teawith2sugars
for all the difference it makes. -
@psychobunny you'll not be able to discourage me through such little issues I'll rework the settings-PR the next days therefor it's a mix of 3. and 5. in my original post
-
it can be written in teawith2sugars for all the difference it makes
I prefer my tea black to be honest
@psychobunny you'll not be able to discourage me through such little issues
hehe