Take advantage of the ecosystem

Is JavaScript the right language for businesses?

The trade-offs & benefits of betting on JavaScript

Seth Corker
Oct 8, 2019 · 6 min read

Benefits

Three key benefits come to mind when choosing JavaScript. A rich ecosystem, impressive cross-platform support, and ease of development.

Photo by David Clode on Unsplash

Rich ecosystem

JavaScript has a vibrant and evolving ecosystem that is constantly growing. The popularity of JavaScript and npm has lead to an explosion of packages to help you focus on business objectives and deliver products quickly. There are many options available for whatever goal you need to achieve and great documentation that underpins these libraries. There are even sub-ecosystems built around libraries like React or web frameworks such as Angular and Vue. Having a good selection of high quality tools, libraries and support adds to the developer experience and makes developers more productive.

Photo by Kelsey Knight on Unsplash

JavaScript runs everywhere

There was a time when JavaScript ran in the browser and it wasn’t taken seriously. This is no longer the case. A JavaScript developer can become competent in the language and use their skills to target a multitude of platforms.

  • Create close to native apps on iOS, Android, Windows, MacOS and Linux.
  • Software for IoT devices
  • Power the infrastructure behind the product on servers.
Photo by Marc-Olivier Jodoin on Unsplash

Speed of development

Rapid development is the combined benefit of a vibrant ecosystem which runs almost anywhere. It’s quick to develop your product with JavaScript because there are libraries and frameworks available. It’s quick to scale up a development team because the popularity of JS brings with it a large pool of talented developers. Your team is more flexible because each developer can work in multiple codebases for products running on different devices, being proficient in the language they know.

Trade-offs

The biggest trade-offs when using JavaScript in production, mirrors the same benefits it offers. Like a many things in programming, blessings can actually be curses in disguise. Every benefit has an equal and opposite trade-off. These should be considered before making a decision.

Photo by Richard Lee on Unsplash

Abundance of choice and conflicting opinions

With so much choice in the JavaScript ecosystem, it can be pretty overwhelming. With such a wide gamut of backgrounds and goals, developers create competing libraries all the time. It’s common to see articles comparing different tools, technologies and paradigms. There is no a single source of truth, rather many sources all competing against each other.

  • Is webpack better than rollup.js?
  • How will components be styled? CSS, SCSS, CSS-in-JS?
  • Which web framework for Node.js is the fastest/easiest/powerful?
  • What rules should we use for linting?
Photo by Amy Elting on Unsplash

A complex build system

The freedom that the JavaScript ecosystem provides results in a build system that can be complex and slow. Putting mobile and desktop aside, the build system for a modern frontend project may consist of many different steps that transform the JavaScript which is written into JavaScript that runs on the browsers you’re actually targeting. The decisions you and your team made earlier may come back to bite you.

Photo by Steve Johnson on Unsplash

Speed of redevelopment

JavaScript is a language which allows developers to hack something together quickly. This is great for prototyping or small scale projects but the linger lived the project, the more room there is for error. The most freeing thing in JavaScript is the ability to get something working even if execution might result in a runtime exception. Although freeing at first, runtime exceptions become the most frustrating errors to debug. They lurk in the code base until you happen across them in your development environment. If you’re unlucky then a user might even experience a runtime error which has a negative impact on how users perceive your product. JavaScript alone is challenging to get right in larger teams which is why it’s often supplemented with tooling.

How to Evaluate

An easy way to answer tell if JavaScript is right for your business is to say it depends but that’s not very helpful advice. Instead, ask yourself the following key questions.

  • Are you targeting mobile? Do you need a native experience?
  • What are your developers familiar with?

Benevolent Bytes

Thoughts, stories and ideas about development. Web development and beyond.

Seth Corker

Written by

Sharing ideas, facts, and opinions about programming. 📚 Learn more React and JavaScript. 🗺 Learn web development tips and tricks 🛸 Discover something new

Benevolent Bytes

Thoughts, stories and ideas about development. Web development and beyond.

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade