πŸš€ DAY 5 OF LAUNCH WEEK: Introducing Socket Firewall Enterprise.Learn more β†’
Socket
Book a DemoInstallSign in
Socket

ndk-svelte

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ndk-svelte

CLI for managing NDK Svelte components

latest
npmnpm
Version
0.2.3
Version published
Maintainers
1
Created
Source

ndk-svelte CLI

Command-line tool for managing NDK Svelte components.

Installation

The CLI is designed to be used with npx without installation:

npx ndk-svelte add event-card

Or install globally:

npm install -g ndk-svelte

Commands

add

Add NDK components to your project.

# Add specific components
npx ndk-svelte add event-card user-profile

# Add a single component
npx ndk-svelte add event-card

# List available components
npx ndk-svelte add

# Install all components (requires --yes)
npx ndk-svelte add --all --yes

# Overwrite existing files
npx ndk-svelte add event-card --overwrite

Options:

  • [components...] - Component names to add
  • -a, --all - Install all available components
  • -o, --overwrite - Overwrite existing files
  • -y, --yes - Skip confirmation prompts
  • -p, --path <path> - Custom installation path
  • --registry <url> - Custom registry URL (default: https://shadcn.ndk.fyi)

upgrade

Check for component updates and optionally upgrade them.

# Check for updates
npx ndk-svelte upgrade

# Auto-upgrade all components
npx ndk-svelte upgrade --yes

# Use custom registry
npx ndk-svelte upgrade --registry https://custom-registry.com

Options:

  • -y, --yes - Auto-upgrade all components without prompting
  • --registry <url> - Custom registry URL (default: https://shadcn.ndk.fyi)

How It Works

  • Scans your project for files with @ndk-version headers
  • Fetches latest versions from the registry
  • Compares versions and shows available upgrades
  • Upgrades components using npx shadcn-svelte@latest add <component>

Example Output

πŸš€ NDK Svelte Component Upgrade Tool

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
πŸ” Scanning project for NDK components...

πŸ“ Scanning src/ (42 files)

βœ“ Found 3 NDK component(s):

  πŸ“¦ event-card v0.8.0 (8 file(s))
  πŸ“¦ user-profile v0.15.0 (13 file(s))
  πŸ“¦ zap-button v0.5.0 (1 file(s))

πŸ“‘ Checking for updates from https://shadcn.ndk.fyi...

βœ“ Registry version: 4.0.0-beta.22

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

πŸ”” 2 component(s) can be upgraded:

  πŸ“¦ event-card
     Event Card
     0.8.0 β†’ 0.14.0

  πŸ“¦ user-profile
     User Profile
     0.15.0 β†’ 0.18.0

πŸ’‘ To upgrade all components, run:
   npx ndk-svelte upgrade --yes

   Or upgrade individually:
   npx shadcn-svelte@latest add event-card
   npx shadcn-svelte@latest add user-profile

Version Headers

Components installed with npx shadcn-svelte@latest add include version headers:

Svelte files:

<!-- @ndk-version: event-card@0.14.0 -->
<script>
  // Component code
</script>

TypeScript/JavaScript files:

// @ndk-version: event-card@0.14.0
export function something() { }

The CLI scans these headers to determine which components you have installed and their versions.

Publishing

To publish a new version:

npm version patch  # or minor, or major
npm publish

Keywords

ndk

FAQs

Package last updated on 29 Oct 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts