Below you can find a collection of the most important Node.js updates, tutorials & announcements from this week – curated by RisingStack’s Node.js Consultants.
Latest Node.js Updates here: 10.16.3 LTS / 12.12.0 Current
First, let’s start with “official” Node news:
- build: Add –force-context-aware flag to prevent usage of native node addons that aren’t context aware
- deprecations: Add documentation-only deprecation for
- esm: Using JSON modules is experimental again
- fs: Introduce
fs.Dirto iterate through directories
- process: Add source-map support to stack traces by using
- Add option for private keys for OpenSSL engines
Did you know that you can already check out Node 13?
With the GitHub Package Registry you can safely publish and consume packages within your org.
According to Isaac Schlueter, the right strategy for “building a sustainable engine behind an open source labor of love” might well be a return to npm’s roots.
In this article we will be going over the steps needed to integrate Stripe Billing with an onboarding flow using Node.js and React. In the guide we will be:
- Configuring a Stripe account with a pricing strategy we will be using in this example
- Setting up a Route in ExpressJS which will expose the pricing strategy to the front-end
- Setting up a React front-end which will handle the onboarding flow, utilizing Stripe Elements for checkout
Practice your Node.js-terminal skills by building your own CLI spinners.
Chalk has been the most widely used library for adding color effects on our Node CLI project. Most people are unaware of how Sindre Sorhus implemented the library, so I decided to take my time out to write about it.
In this post, we will see how to write colors to our terminal using Nodejs.
I had an interesting problem that melted my brain a bit. Let me share what I have learned and maybe save you a few moments when you come across a similar challenge.
Recently I’ve been working on a Node.js project where we needed to keep track of which requests were generating calls to some other pieces of code. Passing a request identifier around was not viable since it would require to change too many APIs.
We solved the problem using cls-hooked, a small package that uses the async_hooks experimental Node.js API to implement Continuation Local Storage.
We can all agree that our project architecture is extremely important, and we can also declare a few points that can help us determine what this architecture must help us do:
- Achieve clean and readable code
- Achieve reusable pieces of code across our application
- Help us to avoid repetitions
- Make life easier when adding a new feature into our application
Interesting JS & Node Discussions:
Do people really ask questions like these?
Hard times for npm when github prepares to step in.