Tag

package.json

0 views collected around this technical thread.

ByteFE
ByteFE
Apr 9, 2024 · Fundamentals

Understanding and Managing Dependencies in Node.js Projects

This article explores the hidden complexities of dependency management in modern Node.js development, covering the risks of unstable package structures, versioning pitfalls, various dependency types, ghost and circular dependencies, and provides practical strategies and best‑practice recommendations to keep dependency graphs stable, secure, and maintainable.

Node.jsdependency managementnpm
0 likes · 28 min read
Understanding and Managing Dependencies in Node.js Projects
DaTaobao Tech
DaTaobao Tech
Sep 13, 2022 · Backend Development

Developing a Node.js CLI Scaffold: Tools, Package.json and Demo

This guide walks you through building a custom Node.js CLI scaffold using commander, chalk, inquirer, ora, and download‑git‑repo, explains essential package.json fields like bin and engines, and provides a complete demo that prompts users, downloads templates, and initializes projects ready for global installation.

CLINode.jscommander
0 likes · 17 min read
Developing a Node.js CLI Scaffold: Tools, Package.json and Demo
DaTaobao Tech
DaTaobao Tech
Aug 1, 2022 · Backend Development

Configuring Dynamic Entry Points for Node Packages: main, type, exports, and module fields

Library authors can configure package.json using main, type, exports, and module fields to provide separate CommonJS and ES module entry points, enabling runtime selection based on import or require, improving tree‑shaking, bundler compatibility, and TypeScript type resolution while restricting undefined sub‑paths.

CommonJSESMExports
0 likes · 11 min read
Configuring Dynamic Entry Points for Node Packages: main, type, exports, and module fields
Rare Earth Juejin Tech Community
Rare Earth Juejin Tech Community
Apr 24, 2022 · Backend Development

How to Properly Create a Qualified npm Package with TypeScript: A Step‑by‑Step Guide

This article walks readers through the complete process of building a well‑structured npm package using TypeScript, covering project initialization, package.json configuration, essential tooling such as husky, lint‑staged, eslint, prettier, unit testing with Jest, and best practices for documentation and publishing.

Jesteslinthusky
0 likes · 15 min read
How to Properly Create a Qualified npm Package with TypeScript: A Step‑by‑Step Guide
ByteDance ADFE Team
ByteDance ADFE Team
Jan 12, 2022 · Frontend Development

Designing and Publishing Module Packages in a Monorepo: Best Practices for Shared Config, UI Libraries, and Native Modules

This article explains how to design, build, and publish reusable module packages—including shared configuration libraries, UI component libraries, and native language modules—within a monorepo, covering package.json configuration, multiple entry formats (ESM, CJS, UMD), tooling choices, and publishing workflows for both frontend and Node.js projects.

Module DesignMonorepoNode.js
0 likes · 19 min read
Designing and Publishing Module Packages in a Monorepo: Best Practices for Shared Config, UI Libraries, and Native Modules
Rare Earth Juejin Tech Community
Rare Earth Juejin Tech Community
Nov 2, 2021 · Frontend Development

Comprehensive Guide to package.json Configuration in Frontend Projects

This article provides an in‑depth overview of the package.json file used in frontend projects, covering required fields, description metadata, dependency sections, script commands, file and directory settings, publishing options, and common third‑party configurations with practical code examples.

ConfigurationScriptsdependencies
0 likes · 22 min read
Comprehensive Guide to package.json Configuration in Frontend Projects
ByteFE
ByteFE
Aug 16, 2021 · Backend Development

Understanding yarn.lock: Why It Changes and How to Manage It

This article explains the purpose and structure of yarn.lock, why it may show unexpected diffs after dependency updates, and provides practical strategies—including using resolutions, frozen lockfiles, and preventive workflows—to keep package.json and yarn.lock in sync and avoid build issues.

YARNdependency managementlockfile
0 likes · 12 min read
Understanding yarn.lock: Why It Changes and How to Manage It
System Architect Go
System Architect Go
Mar 6, 2017 · Backend Development

Understanding npm Scripts and Custom Commands in Node.js Projects

This article explains the role of the scripts section in a Node.js project's package.json, clarifies why commands like npm start work without the run keyword, and shows how to correctly execute custom scripts using npm run, helping developers avoid common pitfalls.

Backend DevelopmentNode.jsScripts
0 likes · 3 min read
Understanding npm Scripts and Custom Commands in Node.js Projects