my8bird / node-leveldb

NodeJS bindings to levelDB - a fast and lightweight key/value database library
http://code.google.com/p/leveldb/
BSD 2-Clause "Simplified" License
63 stars 12 forks source link

Why CoffeeScript? #6

Closed pvorb closed 12 years ago

pvorb commented 12 years ago

Wouldn't it be more convenient to use JavaScript instead of CoffeScript for the non C++ parts?

I find it very hard to read CoffeeScript code and so do many others and would say that such an essential library use as less dependencies as possible, since it doesn't make anything easier.

What's the reason for using CoffeeScript?

my8bird commented 12 years ago

The coffeescript vs javascript debate has been raging elsewhere and I do not wish to go down that road here. I used coffeescript because I wanted to to learn it, and learning is why I got started on this project. I find coffeescript very easy to read, as I do Javascript, and I jump between them both easily. This is most likely do to my use of ruby and python as well.

I do mean this in a bad way but if you intend to use node you will more then likely need to get used to coffeescript as there is a large population of people who believe it is the one true way. I do not believe this but I do find it refreshing and enjoyable.

As to this libraries use of coffeescript in the future it may change to to straight JS but for now the non-C++ code is so small it is hardly worth the effort to port.

pvorb commented 12 years ago

Okay. I don't want to doubt you and your work. I'm not new to node, but never had to contribute to a project that used CoffeeScript, because only about 5% use it.

I think I'll have to learn some basic parts of CoffeeScript to be able to contribute to node-leveldb.

Sorry for the distraction. It's a very good project btw.