Node.js: Avoid the Noid

"If I am happy with the same code I wrote a year ago, I am not improving as a coder."

In an effort to improve my skill set, I have taken the plunge into 3rd party javascript frameworks.

The Rails world has taught me so much. Ruby opened my eyes to a beautiful language that is unparalleled in its succinctness and subtly. With a shallow learning curve and a vibrant community, anyone can pick up the basics in a couple weeks. I will continue to keep with the trends and hone my RoR knowledge.

Now, everyone has suggested Backbone.js. Its lightweight and modular. Written by the same guy who developed coffeescript, one can quickly build organized and beautiful webapps. Moving work from the server side to the client side is the future.

A couple things I hope to master in the coming weeks:

  • Explore the various ways backbone can interface with the server via a RESTFUL api. I want to be able to write my own api and the options here are intriguing, whether on sinatra server, or integrated in a Rails backend where my restful routes would be setup automatically for me could be convenient, there is also the Java and JSONP way which seems to the most basic, also ive seen alot of implementations where the routes and db is local via Couchdb or IndexxedDB etc
  • Master the best practices in regards to app organization. There seems to be not one way to do this, backbone gives you a theory but leaves it up the developer to organize, probably best, id definitely want to namespace my code. This also leads me to Ember.js or require.js, I understand require but it seems overkill for now, ember seems a good starting off point for me, its very secluded by nature like Bundler in the Rails world.
  • How easy is it to test my app? Being quite familiar with RSpec integration testing and Cucumber acceptance testing, will I have any problems migrating to a Jasmine approach, or QUnits(may be wrong here) Testing for me has typically slowed down my development but it is invaluable in keeping a good record of development and the more I do it, Ill get better of course and down the road I'll be able to refine my approach and see what works for me.
  • I already validate all my javascript via JSLint but I'd like this to be in real time, this leads me to tools, I've been on Sublime Text 2 for a while now and I'm comfortable in it, but is this the best way to write my code, I do miss real time code feedback like in Eclipse or XCode.
  • I really need to pay more attention to jQuery, its so powerful and quite ubiquitous now, I've always used it when I needed it to solve a problem. I rarely delved down into the docs and consider the true purpose of the library. I mean I understand ajax but I always used the shortcut .get or .post, my animations always worked but reading some blog posts on the animation queue showed me how incorrectly I was doing things.

In school they taught us in C and Java but at least it was a good education and they focused more on theory. This allowed to pick up a language in the real world quickly but that was 5-6 years ago. My mind hasn't been challenged, I hope this new trek into a serious MVC JS frameworks challenges me and I'm able to write beautifully functioning code.

Stay tuned for such projects as: * A test website designed solely to explore the feasibility of keyboard only navigation * A grid framework tailored for Metro/Win8 sites * A personal analytics site. A 'you give me data, I model it for you'