June 11, 2024
Getting started with JavaScript for Python developers
There's tons of choices to make when beginning with JavaScript development. But there's sane defaults you should try out.
In the Zen of Python, it is said that “There should be one– and preferably only one –obvious way to do it.” This is very unlike JavaScript, where a popular saying goes “There’s a new framework every week”. Interestingly, this is also the case for package management, meta-frameworks, and pretty much every other aspect of JavaScript development. Whilst there’s definitely positives to being spoilt for choice, you can easily get burnt by continuously trying out the newest and greatest.
Now, if you’re part of the No Build Movement, then you can easily skip this article, but for the rest of you, I’ve come with help. Now, I’ve definitely made the mistake of trying out all the options: just see the 5 versions of this website. However, I’ve learnt my lesson and I hope to help you avoid going through a similar process.
In Python development, you have a single Python runtime, a single package manage (pip), and a well established web framework (Django). Okay, there’s also Flask, uv, Poetry and a few others, but the point is that there’s a few well established sane defaults that you can’t go wrong with. In JavaScript development, you’re immediately faced with all these choices, and it can be overwhelming.
In the following, I’ll outline some sane defaults for JavaScript development that you should try out. They’ll get you going and you can enjoy making awesome web applications without spending weeks/months trialing different frameworks and toolings (like me).
So, if you’re ready to get that JavaScript project shipped, let’s get started!
“Installing” JavaScript
Whilst JavaScript can run in browsers, modern development requires tooling beyond the capabilities of browsers. As a Python developer you’re used to installing Python from the Python website. For JavaScript, the equivalent is Node.js, which is a JavaScript runtime that enables you to run JavaScript outside browsers
As hinted in the intro, there’s a plethora of options for JavaScript runtimes, so already now you’re faced with a choice. Other popular options, include Deno and the newest and hottest: Bun. In line with the overall theme of this article, I’m going to advice against hopping onto the newest and greatest, and instead, I’d recommend starting out with Node.js, unless you have a very specific requirement that Node.js doesn’t meet.
Sure, Bun can be significantly faster than Node.js, but you’re unlikely to run into performance issues using Node.js, especially if you keep your code well optimized and avoid introducing unnecessary dependencies.
On the other hand, what you do get by using Node.js is a mostly painless experience with limited bugs and plenty of documentation (of said bugs). Even though this is always welcome, it’s especially important in JavaScript development due to the rapid development pace.
In line with this sentiment, you should install the LTS release (Long Term Support) of Node.js. You can generally expect packages to be compatible with this release and you avoid having to debug cryptic error messages before you’ve even started.
How many package managers do you need?
In Python, you’re most likely used to using pip for installing and updating Python packages. There’s of course also Poetry (and uv), but pip is a well established choice for the majority. Similarly, in JavaScript, there’s a sane default in npm. It’s the default package manager for Node.js and comes pre-installed with Node.js. The great thing is that you can expect most packages to be available and compatible with npm.
Other options include, Yarn and pnpm. Again, these options can be faster and more optimized than npm, but it’s very unlikely that you’ll notice any differences.
What I have noticed, on the other hand, are bugs. And, then you have to ask yourself, are you able to find the source of that bug and fix it within the 10 seconds you saved by using an optimized package manager? If that’s you, why are you reading this post?
Sure, it feels good to have packages install faster, but what feels really great? A package manager that just works. In all honesty, there’s a close to 0% probability that the defining feature that really made you ship that project was the 10 seconds saved on package installation.
Choosing your flavor of JavaScript
Okay, you have a JavaScript runtime and a package manager, you’re ready to go! Just install some packages and be done with it.
If only it was so simple.
Well, it’s also not so hard. Just install React and go crazy. Which is the shortest way of describing that you should probably just stick to the standard when you’re getting your feet wet in JavaScript development. React is massively popular and not without warrant.
But before you do so, let’s dig a little bit deeper into why you would want to do so.
The most common way of working with JavaScript is to use either a library or a framework to help you and to avoid having to rewrite core functionality from scratch. Similar to how, you’d probably not want to remake pandas, numpy or requests in Python.
Work in progress…
Who am I?
Hi, I'm Claes Nymand Nilsson, and I am a Danish biotech engineer and software developer with a passion for science, technology, sports and photography.
I've been working in the biotech industry since May 2016, now 10+ years, and have worked extensively with bioreactors, perfusion cultivation, recovery, TFF optimization, software development, and data analysis.

