Node.js Icon

Node.js

Node.js is a tool for executing JavaScript in a variety of environments.
188 Stories
All Topics

Node.js github.com

A lightweight and powerful wiki app built on Node

I’m not sure what makes this lightweight (their word, not mine), but it does load pretty fast from where I’m accessing it. I definitely see what they mean by powerful, though, as wiki.js boasts many features: multiple editors, multiple auth schemes, search functions, comments, multiple locales, the list goes on…

The demo is worth a thousand words.

Node.js github.com

An extremely fast and lightweight test runner for Node and the browser

uvu has minimal dependencies and supports both async/await style tests and ES modules, but it’s not immediately clear to me why it benchmarks so well against the likes of Jest and Mocha.

~> "jest"  took  1,630ms  (861  ms)
~> "mocha" took    215ms  (  3  ms)
~> "tape"  took    132ms  (  ???  )
~> "uvu"   took     74ms  (  1.4ms)

The benchmark suites are pretty basic, so it’d be cool to see a “production” grade library or application port their test suite to uvu for comparison.

Smashing Magazine Icon Smashing Magazine

Aleem Isiaka explores Node's internals

This is a nice, Smashing deep-dive by the author of React HereMaps:

Armed with basic knowledge, beginner and intermediate developers of Node.js struggle with many things: “It’s just a runtime!” “It has event loops!” “Node.js is single-threaded like JavaScript!”
While some of these claims are true, we will dig deeper into the Node.js runtime, understanding how it runs JavaScript, seeing whether it actually is single-threaded, and, finally, better understanding the interconnection between its core dependencies, V8 and libuv.

React github.com

A simplified Jira clone built with React and Node

This looks like an excellent read for anyone looking to level up their fullstack JS chops:

I do React consulting and this is a showcase product I’ve built in my spare time. It’s a very good example of modern, real-world React codebase.

There are many showcase/example React projects out there but most of them are way too simple. I like to think that this codebase contains enough complexity to offer valuable insights to React developers of all skill levels while still being relatively easy to understand.

A simplified Jira clone built with React and Node

Node.js github.com

Playwright is a Node library to automate the Chromium, WebKit, and Firefox browsers

Playwright is focused on enabling cross-browser web automation platform that is ever-green, capable, reliable and fast. Our primary goal with Playwright is to improve automated UI testing by eliminating flakiness, improving the speed of execution and offering insights into the browser operation.

From the Microsoft Edge team.

Node.js github.com

The largest Node.js best practices list

With 35k+ stars, I might be the last one to the party on this awesome repo.

It is the largest compilation, and it is growing every week - currently, more than 80 best practices, style guides, and architectural tips are presented. New issues and pull requests are created every day to keep this live book updated. We’d love to see you contributing here, whether that is fixing code mistakes, helping with translations, or suggesting brilliant new ideas.

Node.js github.com

Jsfuzz – a coverage-guided fuzzer for testing JavaScript/Node packages

Fuzzing for safe languages like nodejs is a powerful strategy for finding bugs like unhandled exceptions, logic bugs, security bugs that arise from both logic bugs and Denial-of-Service caused by hangs and excessive memory usage.

As we recently learned on Go Time: pessimists write tests, fuzz functions, and sleep well at night. 💤

JavaScript levelup.gitconnected.com

Moving beyond console.log() — 8 console methods you should use when debugging JS and Node

When talking about the Console API, newbies usually use only some functions like 👌console.log(), ⚠️ console.warn(), or ❌ console.error() to debug their application, while often there are many other methods which can perfectly implement our requirements and improve debugging efficiency.

Guilty! ✋

This article is made to expose some of the most interesting console methods with related examples that I use while teaching at Codeworks. So let’s see a list of the 8 best functions from the Console module!

I have used console.table a few times (totally rad), but there’s plenty of functions here that I haven’t been using (and definitely should be).

Liran Tal Snyk

Sequelize ORM found vulnerable to SQL injection

SQL injection is a serious vulnerability, effectively allowing an attacker to run roughshod over your entire database. If you’re using Sequelize, drop everything (pun unintended) and get patched up.

As a testament for Sequelize’s commitment to security and protecting their users as fast as possible, they promptly responded and released fixes in the 3.x and 5.x branches of the library, remediating the vulnerability and providing users with an upgrade path for SQL injection prevention.

ehmicky github.com

A simpler, faster alternative to `nvm run`

nve differentiates itself from nvm run because it:

  • can be run programmatically
  • is 10 times faster
  • does not need a separate installation step for each Node version
  • works on Windows
  • does not require Bash
  • is installed as a Node module

Worth noting: this is not a full-on replacement for nvm or any other version manager. It only executes a single command with the specified Node version. But sometimes, that’s all you need. 😄

SQLite github.com

Sqlite To Rest

LGTM, but why?

Mostly because I wanted to dig deeper into node web server code, but also because I haven’t jumped onto the NoSQL bandwagon and think that web APIs are extremely useful. The result is a modest attempt at automating the CRUD boilerplate that every developer hates, while following the specs to make API consumption intuitive. I chose sqlite to keep the database side of things simple, with the intent that the API isn’t serving heavy loads.

Liran Tal DEV.to

How to securely build Docker images for Node.js

Liran Tal:

Developers, often lacking insights into the intricacies of Docker, may set out to build their Node.js-based docker images by following naive tutorials which lack good security approaches in how an image is built. One of these nuances is the use of proper permissions when building Docker images.

To minimize exposure, opt-in to create a dedicated user and a dedicated group in the Docker image for the application; use the USER directive in the Dockerfile to ensure the container runs the application with the least privileged access possible.

Chi Wang deskgap.com

Deskgap — build cross-platform desktop apps with web technologies

Stop me if you’ve heard this one before…the difference is DeskGap leverages the operating system‘s webview instead of baking a browser in with it (like Electron).

DeskGap is a framework for building cross-platform desktop apps with web technologies (JavaScript, HTML and CSS).

To enable native capabilities while keeping the size down, DeskGap bundles a Node.js runtime and leaves the HTML rendering to the operating system‘s webview.

Evan You github.com

Build your own Mint (finance analytics) with Plaid, Google Sheets, and CircleCI

Mint is super cool, but handing over your precious financial information to a 3rd-party is always a bit nerve-racking. Evan You’s new Node app builds a bridge between Plaid (for bank access) and Google Sheets (for data storage) so you can roll your own system.

Now you only have to trust your precious financial information to two 3rd-parties 😉. But! This is open source so at least you don’t have to trust the application code.

Eran Hammer Medium

Why you should consider hapi

Eran Hammer makes the case for hapi as your Node web framework of choice. We’ve been talking about dependencies a lot lately due to recent events. In light of that, think about this:

hapi was the first (and still the only) framework without any external code dependencies… I personally (and manually) review every single line of code that goes into hapi (excluding node itself). I review every pull request on every dependency regardless if I am the lead maintainer.

That’s quite the selling point! He has a lot of great reasons why hapi is worthy of your consideration. Click through for the hard pitch.

0:00 / 0:00