Explore npm package source code locally. Use when needing to understand a library's API, types, or implementation.
Downloads and explores npm package source code locally for API and implementation analysis.
/plugin marketplace add jasonkuhrt/claude-marketplace/plugin install typescript@jasonkuhrtThis skill inherits all available tools. When active, it can use any tool Claude has access to.
Get npm package source code locally for reading, stored globally to amortize across projects.
All packages stored in: ~/.claude/package-sources/<package-name>/
ls ~/.claude/package-sources/<package-name>/ 2>/dev/null
If exists, check if update needed:
cd ~/.claude/package-sources/<package-name> && npm outdated 2>/dev/null
CRITICAL: Use npm pack + extract, NOT git clone. This gets the actual published package (post-build) matching what's installed in projects, not raw source that may need complex builds.
mkdir -p ~/.claude/package-sources/<package-name>
cd ~/.claude/package-sources/<package-name>
npm pack <package-name> && tar -xzf *.tgz --strip-components=1 && rm *.tgz
This gives you:
Only if you need original TypeScript source or tests:
# Get repo URL from package.json
npm view <package-name> repository.url
# Clone to separate directory
git clone --depth 1 <repo-url> ~/.claude/package-sources/<package-name>-src
Start with:
package.json - exports map, main entryUse Serena MCP's symbolic tools for efficient navigation.
cd ~/.claude/package-sources/<package-name>
rm -rf * && npm pack <package-name> && tar -xzf *.tgz --strip-components=1 && rm *.tgz
For specific version matching your project:
npm pack <package-name>@<version>
Check project's version:
cat package.json | grep '"<package-name>"'
# or
pnpm list <package-name>
npm pack over git clone - gets published output, not complex sourceThis skill should be used when the user asks about libraries, frameworks, API references, or needs code examples. Activates for setup questions, code generation involving libraries, or mentions of specific frameworks like React, Vue, Next.js, Prisma, Supabase, etc.