deps
Manage dependencies with npm/yarn/pnpm. Use for auditing vulnerabilities, checking outdated packages, understanding dependency trees, and upgrading packages safely.
What this skill does
# Dependencies Manager Audit, analyze, and manage project dependencies. ## Prerequisites At least one package manager: ```bash # npm (comes with Node.js) node --version # yarn npm install -g yarn # pnpm npm install -g pnpm ``` For dependency analysis: ```bash npm install -g depcheck ``` ## CLI Reference ### Security Audit #### npm ```bash # Run security audit npm audit # JSON output npm audit --json # Only production deps npm audit --omit=dev # Fix automatically npm audit fix # Fix with breaking changes (careful!) npm audit fix --force ``` #### yarn ```bash yarn audit yarn audit --json ``` #### pnpm ```bash pnpm audit pnpm audit --json ``` ### Check Outdated Packages #### npm ```bash # List outdated npm outdated # JSON output npm outdated --json # Long format with details npm outdated --long ``` #### yarn ```bash yarn outdated ``` #### pnpm ```bash pnpm outdated pnpm outdated --json ``` ### Upgrade Packages #### npm ```bash # Update to latest within semver range npm update # Update specific package npm update lodash # Install latest (ignoring semver) npm install lodash@latest # Interactive upgrade (with npm-check) npx npm-check -u ``` #### yarn ```bash yarn upgrade yarn upgrade lodash yarn upgrade lodash@latest yarn upgrade-interactive ``` #### pnpm ```bash pnpm update pnpm update lodash pnpm update lodash --latest pnpm update --interactive ``` ### Dependency Analysis #### Why is this package installed? ```bash # npm npm explain lodash npm ls lodash # yarn yarn why lodash # pnpm pnpm why lodash ``` #### Find unused dependencies ```bash npx depcheck # JSON output npx depcheck --json # Ignore patterns npx depcheck --ignores="@types/*,eslint-*" ``` ### View Package Info ```bash # View package details npm view lodash # Specific fields npm view lodash version npm view lodash versions npm view lodash dependencies npm view lodash repository.url # JSON output npm view lodash --json ``` ### Dependency Tree ```bash # Full tree npm ls # Specific depth npm ls --depth=2 # Production only npm ls --omit=dev # Specific package npm ls lodash # JSON npm ls --json ``` ## Workflow Patterns ### Security Audit Workflow ```bash # 1. Run audit npm audit --json > audit-report.json # 2. Review high/critical npm audit --audit-level=high # 3. Auto-fix what's safe npm audit fix # 4. Manually review remaining npm audit ``` ### Upgrade Workflow ```bash # 1. Check what's outdated npm outdated --json # 2. Test current state npm test # 3. Update patch/minor versions (safer) npm update # 4. Test again npm test # 5. Update major versions one at a time npm install package@latest npm test ``` ### Dependency Cleanup ```bash # 1. Find unused deps npx depcheck # 2. Review and remove npm uninstall unused-package # 3. Verify npm test && npm run build ``` ### Investigating a Package ```bash # Package info npm view express # Current version in project npm ls express # Who depends on it npm explain express # Security vulnerabilities npm audit | grep express ``` ## Common Issues ### Peer Dependency Warnings ```bash # See peer deps npm ls --json | grep peer # Install missing peer deps npm install missing-peer-dep ``` ### Version Conflicts ```bash # See duplicate packages npm ls --all | grep "deduped" # Force dedupe npm dedupe ``` ### Lock File Issues ```bash # Regenerate lock file rm package-lock.json npm install # Or for yarn rm yarn.lock yarn install ``` ## Best Practices 1. **Audit regularly** - Run `npm audit` weekly or in CI 2. **Update incrementally** - One major version at a time 3. **Test after updates** - Always run tests post-update 4. **Review before fixing** - `npm audit fix --force` can break things 5. **Clean unused deps** - Run `depcheck` periodically 6. **Lock versions** - Commit lock files to git 7. **Check before adding** - Review package health before installing
Related in General
modeling-omnistudio-epc-catalog
IncludedSalesforce Industries CME EPC product-modeling skill for Product2-based catalog creation. Use when creating EPC products, configuring product attributes, building offer bundles with Product Child Items, or reviewing EPC DataPack JSON metadata for product catalog changes. TRIGGER when: user creates or updates Product2 EPC records, AttributeAssignment payloads, AttributeMetadata/AttributeDefaultValues, Offer bundles, or ProductChildItem relationships. DO NOT TRIGGER when: designing OmniScripts/FlexCards/Integration Procedures (use building-omnistudio-omniscript, building-omnistudio-flexcard, or building-omnistudio-integration-procedure), implementing Apex business logic (use generating-apex), or troubleshooting deployment pipelines (use deploying-metadata).
relationship-science-coach
IncludedUse this skill for direct, practical adult relationship coaching: couples conflict, repair, trust, marriage, dating, flirting, attachment patterns, emotional connection, sex, desire differences, eroticism, kink negotiation, affection, love languages, breakups, and long-term passion. Draw on Gottman, EFT and Hold Me Tight, attachment science, modern sex research, Perel, Nagoski, Kerner, Schnarch, Love and Stosny, and flexible love-language tools. Be concrete and low-hedge. Redirect only for imminent danger, abuse, coercive control, minors, non-consent, self-harm, stalking, or medical/legal/psychiatric decisions.
building-sf-integrations
IncludedSalesforce integration architecture and runtime plumbing with 120-point scoring. Use this skill to set up Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, and Change Data Capture. TRIGGER when: user sets up Named Credentials, External Services, REST/SOAP callouts, Platform Events, CDC, or touches .namedCredential-meta.xml files. DO NOT TRIGGER when: Connected App/OAuth config (use configuring-connected-apps), Apex-only logic (use generating-apex), or data import/export (use handling-sf-data).
venue-templates
IncludedAccess comprehensive LaTeX templates, formatting requirements, and submission guidelines for major scientific publication venues (Nature, Science, PLOS, IEEE, ACM), academic conferences (NeurIPS, ICML, CVPR, CHI), research posters, and grant proposals (NSF, NIH, DOE, DARPA). This skill should be used when preparing manuscripts for journal submission, conference papers, research posters, or grant proposals and need venue-specific formatting requirements and templates.
let-fate-decide
IncludedDraws the 12 Houses of the Zodiac Tarot spread to inject entropy into planning when prompts are vague, ambiguous, or casually delegated. Interprets the spread to guide next steps. Use when the user says 'let fate decide', 'YOLO', 'whatever', 'idk', or other nonchalant phrases, makes Yu-Gi-Oh references, or when you are about to arbitrarily pick between multiple reasonable approaches. Prefer over ask-questions-if-underspecified when the user's tone is casual or playful rather than precision-seeking.
net-ops
IncludedCross-platform network troubleshooting (Windows, macOS, Linux) via local or remote shell. Use for: DNS broken, can't resolve hostnames, nslookup/dig works but apps fail, NRPT, WFP, scutil, /etc/resolver, systemd-resolved, /etc/resolv.conf, NetworkManager, VPN DNS leak residue (ProtonVPN/Mullvad/WireGuard/AnyConnect), AV/firewall blocking DNS or DoH, Tailscale DNS interaction, intermittent connectivity, remote diagnostics over SSH.