Skip to content

Latest commit

 

History

History
49 lines (35 loc) · 839 Bytes

File metadata and controls

49 lines (35 loc) · 839 Bytes

Publishing Guide

Step 1: Version the Package

# For patch releases (bug fixes)
npm version patch

# For minor releases (new features)
npm version minor

# For major releases (breaking changes)
npm version major

# Or set version manually
npm version 1.0.0

Step 2: Review Package Contents

# See what files will be published
npm pack --dry-run

# Create a test package (optional)
npm pack

The package should include:

  • dist/ directory with built files
  • package.json
  • README.md
  • src/ directory (excluded)
  • examples/ directory (excluded)
  • ❌ Test files (excluded)

Step 3: Publish to npm

# Login to npm (if not already logged in)
npm login

# Publish the package
npm publish

# For scoped packages or first-time publishing
npm publish --access public