Tagged articles
7 articles
Page 1 of 1
ByteDance Dali Intelligent Technology Team
ByteDance Dali Intelligent Technology Team
Jun 11, 2021 · Backend Development

Node.js Package Module Import/Export Rules and Conditional Exports – A Comprehensive Guide

This article explains the latest Node.js package module specifications, covering how the "type", "exports", and "imports" fields in package.json determine ESM or CommonJS loading, the history of version changes, subpath mappings, conditional exports, and best practices for dual-module packages.

CommonJSESMExports
0 likes · 27 min read
Node.js Package Module Import/Export Rules and Conditional Exports – A Comprehensive Guide
WeDoctor Frontend Technology
WeDoctor Frontend Technology
May 19, 2020 · Backend Development

What Really Happened with the is-promise NPM Incident? A Deep Dive

The article investigates the April 25 NPM outage caused by the is-promise package, explains the buggy code and the problematic "type" and "exports" fields in package.json, reviews the rapid fix timeline, and offers practical lessons for developers to avoid similar dependency mishaps.

Exportsdependency managementis-promise
0 likes · 15 min read
What Really Happened with the is-promise NPM Incident? A Deep Dive
Node Underground
Node Underground
Aug 27, 2019 · Backend Development

Master Node.js Module System: Loading, Caching, and CommonJS Pitfalls

This article explains Node.js's CommonJS module system, covering how require loads modules, the role of module.exports versus exports, module classification, loading order, caching behavior, circular dependencies, and provides practical code examples for interview preparation.

CommonJSExportsNode.js
0 likes · 10 min read
Master Node.js Module System: Loading, Caching, and CommonJS Pitfalls