Tips for developers starting out with Node.js

Starting out as a developer can be daunting, learning a new technology either as a student or a already established programmer usually takes the road of blood, sweat and tears. But learning Node.js can be a lot easier with the help of the amazing community that was built around it.

Here are a few tips from node.js developers and active community members. We hope their tips will help and if you have other useful tricks to share just think about how they helped you and how much they can help others.

A 100% growth rate means that every day new people start to learn Node.js and the great thing about this technology is the support that exists within the community. So if you have other tips for people starting out on Node share them in the comment section.

Here are some tips for Node beginners:

Start simple, do Vanilla, learn to use Node.js itself before moving to modules. Become active in the community, connect and try to contribute, to give back as much and as little as you can.

Wyatt Preul

Product Engineer, Joyent

Take some time and look at what goes on “behind the scenes”, how do the modules work, who writes them and get to know these members of the community and see what you you can learn from them and what are their opinions.

Steven Faulkner

Director of Engineering, Bustle

Use a private npm registry, don’t check in your Node.js modules to Git, be careful of using Git URLs in your package JSON, they can lead to a lot of issues in time, but at the beginning are a nice shortcut.

Charlie Robbins,

Director of Engineering, GoDaddy

Lock your dependencies. He’s really putting his foot down here – just lock them. If you’re going to upgrade Node make sure you let your team know.

If you upgrade Node on your machine and something goes wrong, just remove rm-rf/node_modules and npm install it again. This one is hand on a very practical advice.

James Hush

Software Engineer, NFL

Make sure you handle errors when they occur and make sure you handle them accurately., crash the application when it’s in an unknown state and restart it. Create tests and test them, make sure you have automated tests. Node being a dynamically typed language, he urges you to have some strict data validation.

Paul Milham

Lead Developer, WildWorks

If you’re an experienced developer think about all the stuff you wished you knew, that could have saved you a lot of headaches and frustration. There’s a lot of them, right?

Well, write a few of them up, a lot of people will thank you for them.

The tips mentioned in this articles were recorded in the following video.



Node.js support and release calendar

Node.js versions support and calendar

Node.js V7 vas released in Beta recently, we covered this in an article and got a fair amount of interest in it. As suc,h we decided to cover Node.js versions a bit more broadly, to include more details about how and when are they released. We’re also going to talk about the cycles of support they go through. The Node.js Foundations releases new versions of Node very often (compared to other languages), every six months there is a new major release of Node. They actually have a system of release for them. There are basically two versions a year, one in April (an even numbered version, V6, V8, V10 etc) and one in October (an odd numbered version, V5 V7, V9).

You can check out the current calendar in the above picture.

Here are a few things you should know the release system:

When a new odd numbered version is released (October) the previous version (April, even version) moves to the Active Long Term Support Plan.

The Active Long Term Support Plan (LTS) lasts 18 months and covers every major version of Node.js. The LTS plan covers:

  • Bug fixes;

  • Security updates;

  • Non-semver-major npm updates;

  • Relevant documentation updates;

  • Certain performance improvements where the risk of breaking existing applications is minimal;

  • Changes that introduce large amount of code churn where the risk of breaking existing applications is low and where the change in question may significantly ease the ability to backport future changes due to the reduction in diff noise. (according to the Node.js Foundation)

After the Active LTS period ends each version will have a 12 month maintenance period, after which it will not receive any type of support. The maintenance period includes:

  • only critical bugs,

  • critical security fixes

  • documentation updates

The release schedule was created in such a way that there won’t be more than two active LTS release at the same time. Basically each new version will be the current one for 6 months. When another version is released it becomes the current one and the previous one goes into LTS. After 6 more months the cycle is repeated.

If you don’t know which version to use the Node.js Foundation recommends to:

  • Stay on or upgrade to Node.js v4.2.x if you need stability and have a complex production environment, e.g. you are a medium or large enterprise.

  • Upgrade to Node.js v5.x if you have the ability to upgrade versions quickly and easily without distributing your environment and want to play with the latest features as they arrive.

This month, V7 will be the current version while Node.js V6 moved to its LTS period.



You can sit on the Node Foundation Board of Directors

You, as a registered member of the Node Foundation can run for the Individual membership director’s seat. That’s the good news, the bad news is if you wanted to do that now you’d be a bit disappointed as the nomination process closed on January 15th. There is always next year, as elections are held annually, so let’s get ahead of ourselves and explain the process and steps you need to take if you want to sit on the Node Foundation Board.

The Board of Directors is composed of 12 people, 9 representatives of corporate members, 1 representative of the Technical Steering Committee and 2 individual membership representatives, Feross Aboukhadijeh and Ashley Williams. The former’s seat is up for election. The term length for the individual membership representative is 2 years (they changed the rules this time –  Feross Aboukhadijeh  had a one year term – so that they can have a yearly election), but elections are held each year for one of the seats. This year’s election results will be announced by January 30th.

You can nominate yourself for this position, but first you need to be a registered member of the Foundation.

What are individual members and how can you be one

Individual members are contributors to the Node project, if you are part of any working group or subproject you get free membership. If you’re not a contributor you can become an individual member by paying a yearly $100 fee (as a student you get a 75% discount).

What does a individual membership director do?

As a individual membership director you have to attend board meetings, the Board meets every month, to discuss and approve resolutions regarding the Node Foundation. Several of these meeting take place in person so you need to take that into account as well. However, if needed, the board cover cost for travel and accommodations.

Your responsibility as an Individual Membership Director involves representing the community as a whole. Just like in any other democratic process they voted for you to represent their interest in the board.

Who elects the Individual Membership Director?

The community. Every registered member can cast a vote for the candidate she/he feels will represent the community best.

The current Board of Directors consists of:

  • Chairperson: Danese Cooper, distinguished member of technical staff – open source at PayPal.

  • Vice-Chairperson: Scott Hammond, chief executive officer at Joyent.

  • Secretary: Dan Shaw, chief technology officer at NodeSource.

  • TSC Director: Rod Vagg, chief node officer at NodeSource.

  • Silver-level Director: Brian McCallister, chief technology officer of platforms at Groupon.

  • Silver-level Director: Justin Beckwith, product manager at Google.

  • Director: Todd Moore, vice president of open technology at IBM.

  • Director: Colleen Evans, principal program manager at Microsoft.

  • Director: Rich Sharples, senior director of product management at Red Hat.

  • Director: Imad Sousou, vice president and general manager at Intel.

  • Director: Ashley Williams, individual membership director.

  • Director: Feross Aboukhadijeh, individual membership director.


On January 30th there will be a new member of the board, replacing  Feross Aboukhadijeh. Next year, Ashley Williams’s seat will be up for election, she can run again of course, but so can you. You should also note that in order to get elected you will have to “campaign” and show that you have the drive and experience for this position. Basically you have to show that you are a good candidate. Have a look at last year’s submissions by Feross Aboukhadijeh and Ashley Williams.



5 basic npm command tips

As a Node developer npm is your best friend. Or it should be your best friend, but as a beginner it can be difficult to get around it. It’s a complex system, with plenty of features and it can be intimidating to get a handle of everything. By learning a few tips and tricks, a few shortcuts, you can make your life a lot easier. That being said, let’s dive in and have a look at a few npm tips and tricks.

1 Outdated dependencies

This is a common issues for any type of registry, but there is a simple fix to it.

By running npm outdated in your project you will receive the current version, the version that you need and the latest version.

2 Clean cache

If you want to clear things out to resolve issues with a package, this option is very helpful

Run npm clean

Npm install

3 Help command

Very basic command, but one that can be of great help. Hence the name.

Run: npm help or npm -1 which will give you more information related to subcommands

4 npm version

If you’re not sure which version of npm you’re using you can find out easily with this command

Run: npm -v

If you want/need to update it you can with npm install -g npm

5 Start something new

You have something in mind for a new project? Or a new module that you want to build? Great.

Run npm init.

These are just a few basic tips that can help you get around npm move easily. There are a lot more tips and tricks, if you have any suggestions that other developers might benefit from, feel free to list them in the comment section.



Skycatch: drones, data processing and Node.js

If you’re thinking about Skynet, stop, this is a whole other company. Real, growing, successful and not determined to end mankind. Skycatch was founded in 2013 and has been using Node.js since the very beginning.

What do they do?

The company specialises in drones that make surveying properties a lot easier and cheaper. They build commercial drone data solutions for various fields, including construction, energy or mining. The drones (built by Skycatch) record all the information of the site you want to survey and then give you the data in an accessible form.

Where do they use Node.js?

The short answer is everywhere.

Node.js is a main technology for them, they use it for their drones and back end development and data processing.

Their main task is to look at certain sites and create a database with all the information that the drone records on that location.

For data processing they use a lot of microservices that work together. Node.js is in their own words the “glue” that keeps everything together. The drones are quite attractive, but the main point of the company is data processing. They have Node.js on the drones (Edison board) on their API site and also almost their entire backend is made in Node.js. The general advantage of being able to move very easily from the frontend to the backend is greatly appreciated at Skycatch.  

The fact that Node.js scales easily is also being taken advantaged of, as their work process is not limited to one section. Their developers have the freedom to move throughout the whole production line as needed and because it’s all JavaScript they can do that.

This is a whole other way to use drones in a practical and commercial way, as helper tools. Going beyond their perception of toys or weapons, this role brings more lucrative results and Skycatch is at the forefront of that.

Their drones can record and process images from a site and turn them into a 3D model in a few hours. The same task, done the old fashioned way, would take a week or more, depending on the size of the site.



2017 challenges for Node.js

A new year has began, a new journey for Node.js as a technology and for every developer and professional in the field. Most people start their year with a few resolutions, a few guidelines or challenges for the new year. It’s actually a great way to set yourself some objectives and to try at least to plan a bit. But it’s not just thinking ahead, it’s challenging yourself to do more in the new year. As node.js developers you are working with a technology that is both up and coming and highly valued.

With the Node Foundation the community and the ecosystem are progressing smoothly, there is plenty of transparency and the community members are increasing, so there is a lot of support to go around. Node gets updates regularly, in April we will have a V8 version and in October a V9 version. Basically things are going well and beyond. So what’s the challenge here?

Here are the industries that have adopted node.js so far. It’s a big list, which is very good news.

Also, Node.js is currently the largest open source platform with more than 15 million downloads per month and more than a billion package downloads per week. In less than 7 years Node got to the point having from a few dozen to 1.100 contributors.

We’re in a good place right now, but, there is always a but.

There’s a constant challenge of not getting trapped and overwhelmed in an environment that is evolving rapidly. There’s a constant challenge of not getting stagnant and falling back.

Becoming a better developer is something personal, it’s not related just to Node.js s a technology, it’s connect to your own desire coupled with the possibilities offered by the environment. The Node community is vibrant, with plenty of learning materials and experiences getting showcased so there are a lot of ways you can grow yourself as a developer.

Use the new node versions, read, write, explore and try to keep up with as much as you can in 2017.

Node.js has been adopted by many enterprise size business and also a lot of small startups, our community is a testament of Node companies and startups, but for 2017 it should go bigger and better, the challenge here is not to get capped, to not stumble and fall as it grows, to not divide and go in different directions. The challenge here is not to rest on one’s laurels and take things for granted.



From Java to Node: the Netflix story

The Why

Before node Netflix had a work style and process that was very difficult both for the company and the development teams. They were working on large applications with huge startup times and slow builds.  They had Java on the server, Javascript on the client, so developers had to be great in two very different languages, they had to be really great at different aspects. There was a lot of doing things twice, they had to write everything twice, two ways for data access, rendering, debugging etc.

The pace of the company was slowing down because of all these issues, and the innovation needed to maintain the company competitive and in the spotlight was bogged down.

To simplify everything, and to be able to move the site to a single page application where they could render each page fully, they moved to Node.js. There were several reasons why Netflix chose Node.js.The first and most important one was to have a common language, one that could help them write the same code and run it everywhere and not have developers constant shifting from Java to Javascript. A universal language server and client side was just what they needed to be able to build that single page app, and not worry so much about getting great Java developers and be able to focus more on building a great product experience. Java was on the losing side both in Netflix’s case and in the PayPal story – check it out here.

Another aspect of this transition was the performance that Node.js offered. From a 40 minute + startup time they went to under a minute. That’s not just an improvement, that’s a whole other level of performance. Also, Node has a lot of modules that are mostly open source, can be used quickly and help you get better tracking, quite different from Java where you don’t have all these helping hands.

These were the basic reasons why Netflix turned to Node.js from Java.

The Experience

The first thing that happened was that the team as a whole had to change not just their language ,but also the way mental processes they usually applied. They had to learn the intricacies of Node.js and focus more on that. Also, even though one of the benefits was and is universality, they had to be careful on how they wrote the code, server and client side, they had to take advantage of this upsight and at the same time think really hard about how the written code will be used and how will it scale. They were a bit excited that they would be able to use just one language for both sides, and it will make things so much easier and it did to a degree, but they had to approach things differently on the server and on the client.

Moving to a new architecture they also had get a lot of insights, a topic they had no data on as it was a new technology for them. They had a lot of learning as you go, in different aspects.

The Future

Right now Node.js is used in production for the entire website, but their mobile application runs on other languages as well. As of December 2015 there was a 30 + Node Stack team at Netflix, which is great. They also have planned a container based strategy built on node, which gives them a lot of flexibility, and scale. Together with Node they also used various other technologies like:  Titus, Reactive Socket, Qiro, Docker, Prana etc. One thing is certain for the present and the future, Node.js  is a big part of Netflix, a place where developers can grow and where node innovation can happen.



Get ready for the Node.js Certification Program

Last month, the Node.js Foundation announced the development of a new Node.js certification program, in order to establish a baseline competency for developers. As node.js grows and more organizations adopt it, this certification will make it easier for them to evaluate developers and also for developers to evaluate themselves. The 32 question exam will be available sometime in the second quarter of 2017.

“The Node.js Foundation, with help from incredible community members and core experts, is creating a comprehensive certification program that broadens the funnel of skilled Node.js expertise available. Whether working in enterprise environments or as individual consultants, those who become Node.js Certified Developers will be well-positioned to hit the ground running as a Node.js developer, possessing skills that are in high demand,” said Tracy Hinds, education community manager for the Node.js Foundation.

The program is created in conjunction with the Linux Foundation, who has previous experience in creating training programs and certifications, with several online courses, like  Intro to Linux, Intro to DevOps: Transforming and Improving Operations; Developing Applications for Linux; Kubernetes Fundamentals and others. 

The Node.js Foundation is also taking feedback from the community, taking in questions that will be on actual exam. You can also contribute.

What does it mean to contribute to the program?

You can choose between two roles, you can be an item (topic/question) writer or an item reviewer. 30 people will be the item writing team, and about 12 of these 30 will be on the Item Writing Review Team IWRT.

You need to have some time available for this, more precisely:

  • 1.5 hours for an intro webinar

  • 2 to 5 hours for independently writing and reviewing the question with Item Writing Review Team members this is for items writers & IWRT

  • 5 to 6,  1-hour online meetings to reach consensus, group review, and level items – just for IWRT only

If you’d like to contribute, you can fill in this application.

The Node.js Certification Program is aimed at intermediate-level developers who already know and work in JavaScript and Node.js. According to the questions presented, there will also be available material and resources to learn from (but not created by the Foundation just for the exam). This way anybody can be certified. Pricing for the certification is yet to be determined, but it will be low cost. It will involve coding and will be taken under observation by a proctor via their computer’s camera.

Professional certifications are a very practical way to check proficiency and skill in software development. This isn’t something new, but it is of great interest in the node.js community as many companies and developers have been asking for such a certification for quite a while now.

“There are a lot of people wanting to verify their knowledge of Node,” Tracy Hinds, education community manager for the Foundation. “The test would certify an applicant as an early intermediate Node developer, which means that “they’re not going to know everything, but they can hit the ground running”.



Developing Mobile Applications Using Node.js

Node.js is a server-side JavaScript platform specially designed for efficient and responsive web applications. Not only just web applications but also for mobile to make it fast, scalable and super portable on every platform. It uses Google Chrome’s v8, one of the finest JavaScript engines for running standalone JavaScript programs. Node.js contains a built-in library that allows applications to act as a web server without any software such as HTTP servers. Nowadays, Node.js is getting popular as a server-side platform and is used by IBM, Microsoft, Yahoo!, Walmart, PayPal and GoDaddy and much more.

Why Count on Node.js?

The exclusive features of Node.js are designed to support multi-user, collaborative, real-time web apps that support various network connections with maximum input.
Node.js, or just Node, with or without a JavaScript frontend, makes well-organized use of hardware resources, especially for I/O-intensive services. It also decreases developers’ reasoning and coding loads via several key features, such as:

  • It substitutes the traditional request-response paradigm with a rapid or two-way communication model.
  • Most developers understand  JavaScript, so the development ramp-up is shallow
  • Node.js web sockets run on TCP, not HTTP, so low-overhead client-server communication is enabled in both directions.
  • Usually, using a single language and portable code base between frontend and backend developers saves much time and money.
  • Generally, Developers avoid having to manage I/O blocking and threads.

How Node.js plays a vital role while working with Mobile Apps

Some of the reasons why some mobile developers need Node.js in mobile developing apps, here are few reasons:

  • Node.js has the fastest growing ecosystem with well over 110,000 free JavaScript modules. Tapping into this resource can help you to develop apps faster and more proficiently.
  • Use the similar platform to advance your Server and Mobile apps. Many times your mobile app will have a parallel browser-based application for desktop access. Having one platform and one codebase for both the browser and mobile applications can make the development course far more efficient.

Unfortunately, there is currently no way to implement Node.js on the mobile client side for all leading mobile platforms. Technically, you can run JavaScript on Android, but neither iOS nor Windows which it accepts V8’s JIT compiled code except under special circumstances.

Lastly, real-time mobile services and applications are now the next immense thing. Node.js is designed accurately to support a real-time mobile web. Throw in shortened development cycles, combined frontend/backend teams plus streamlined support and Node.js looks like a winning strategy for servers and mobile devices.



Node.js Will Overtake Java Within a Year: Analysis

This is a statement from Mikeal Rogers, community organizer of the Node.js Foundation, from a recent interview with the New Stack. This is someone who has been involved with Node.js, hands on, since it was released. You can check out the New Stack interview – you can read the full story, but basically he’s been a Node junkie since the second day it was released. That was in 2009.

So, getting to it – Java or Node.js?

Mikeal mentioned that there are currently about 8 million estimated Node.js users with a 100% growth rate per year. Last year the Node.js Foundationed announced that they have 3.5 million users, so the 100% growth rate, at least for the time being, is right on the money.

Basic math would put Node.js users at around 16 million next year. So how many users does Java have?

In 2013 Oracle said that there were 9 million Java developers. In 2007 there were about 6 million. In 2017? Hard to tell.

Oracle hasn’t released any official data on this so it’s just conjecture at this point, but considering their (maybe) growth rate, there should be somewhere between 12-14 million Java developers right now. Again, it’s just a guessing game.

But let’s look at some numbers!

The TIOBE index is an indicator of the popularity of programming languages. Popularity being an important factor for adoption, is a good way to compare the two. The TIOBE rating is based on  the number of skilled engineers world-wide, courses and third party vendors. It used 25 search engines to calculate the index. You can learn more about it here.

Java has been very popular for a long time before Node.js was even released. Checking out the history index in TIOBE we can see that it was the number one language on more than one occasion.

So far, this year it’s again the most popular language. Here’s Java over time.

Now you might be wondering where’s Node related to this. Well, TIOBE doesn’t count node.js because it’s not an individual programming language. That means it gets counted in the JavaScript section.

Nevertheless, the TIOBE index shows a mature and popular Java. That being said, consider that PayPal and Netflix moved from Java to Node.js. Java might be popular, but companies will still change stacks if something better comes along and Node.js has its share of attributes that make the change worthwhile. There are also plenty other Node.js companies to check out.

HackerNews has a whoishirign section and a tracking system for jobs. In the picture below you can see a comparison of Node js (blue) and Java (black) from August 2011 to June 2017. This is also a subjective comparison, it only takes into account the Hacker news platform, but as an indication it follows the same trend as the previous resources mentioned.

See how Node.js grows and occasionally overtakes Java?

Using the Stack Overflow Survey we can directly compare Java and Node.js. Take into account that the survey is representative only for Stack Overflow users.

Again, if we take the programing language section we end up comparing JavaScript and Java as Node.js doesn’t qualify. For the record JavaScript is the most popular programming language, while Java take third place. But in the technology popularity section we can see the evolution on Java and Node.js over the past five years since Stack Overflow started conducting the survey.

Node.js went from 8% in 2013 to 26% in 2017 and Java went from 42% to 39% in the same period (% of respondents that use the language).

Considering the trend(s), even with just a slight drop for Java,  Mikeal’s prediction might be true if the Node.js 100% growth rate carries on.

That means that Node.js in on the right track to take over Java in terms of users.