Why I love JavaScript and Meteor.js

02-11-2013 (d-m-Y)

Context switching

You all know it. You are coding in PHP for a long time, then you need to write something in JavaScript and you are lost. You remember PHP functions, but you have to Google JS functions because you don't remember them. When I coded something in JavaScript, then switched to PHP, I tried to concatenate strings like in JavaScript:

$a += 'b';

instead of

$a .= 'b';

When you write in one universal language, development speed is increased because you focus on one language and you don't have to learn another. And you bet JavaScript is universal language. You can write Windows 8 apps, mobile apps (Phonegap/Cordova), server side apps (NodeJS) and even operating systems (http://nodeos.github.io/).

There are lots of great JavaScript frameworks. Client side: Angular, Backbone, Ember,... and server side: Express, Sails, Geddy, Meteor... and many more. When I just took a quick look at the frameworks I fell in love with Meteor. It was love at first sight. My first Meteor project is http://todotoday.meteor.com and it's quite fast. And realtime.

What Meteor has other frameworks have not?

  • Realtime app from scratch (it's overkill feature)
  • Simple deployment (simplest and fastest i'v ever seen)
  • Live programming - you dont have to refresh page when you want to see your changes. When you change and save file in Meteor project, Meteor will automatically refresh the page.
  • flexible application structure http://docs.meteor.com/#structuringyourapp. This may be confusing for beginners. When I started with Meteor, it took me some time to find the right app structure for me. I will cover this topic in upcoming article.

Other Meteor features:

  • command line - create project with "meteor create projectname", add/remove packages, start meteor server...
  • package management - "meteor add less" will add less package into your project and you can instantly use less instead of css files. Meteor has some built in packages http://docs.meteor.com/#packages and there is community package server https://atmosphere.meteor.com/

Future of Meteor

Recently has been introduced Meteor Marketplace idea http://meteorhacks.com/the-meteor-marketplace.html. As Jidefr mentioned in his comment, implementing this idea could harm current opensource packages idea. Now you can publish your packages for free and help other developers. But if you could sell your package wouldn't you do that? In other hand, paid packages can be copmlex solutions (like forum, chat,...) provided in high quality and customizability.

Meteor has a roadmap on Trello https://trello.com/b/hjBDflxp/meteor-roadmap so you can see what's going to be implemented. Meteor popularity and community is growing every day. Packages count and quality on Atmosphere also grow.

Conclusion

Meteor is still young but powerfull tool. Many people think that Meteor is not ready for production yet (Meteor is not even v1.0. At the time of writing this article it has v0.6.6.2), but I think it is ready. And I will prove it in my next application. Look at NodeJS. Does it have 1.0 version? No. But there are many frameworks, tools and other stuffs built on top of Node. So try Meteor, fall in love with it and build great things.

← All articles | If you want to know about new blogposts you should follow @elfoslav

comments powered by Disqus