Skip to main content

Getting Started: Node.js & TypeScript Projects

A step-by-step guide to scanning Node.js and TypeScript projects with the Vibgrate CLI — from a single package.json to complex monorepos with multiple workspaces.

Vibgrate Docs

Vibgrate Help

Overview

Vibgrate has first-class support for Node.js and TypeScript projects. It detects package.json files, lockfiles (npm, pnpm, yarn), .nvmrc/.node-version configuration, and tsconfig.json compiler options.

What Gets Scanned

  • Runtime version from engines.node, .nvmrc, or .node-version
  • Framework versions (React, Next.js, NestJS, Express, Angular, Vue, Svelte, etc.)
  • All dependencies from package.json (both dependencies and devDependencies)
  • Lockfile analysis for duplicate packages and phantom dependencies
  • TypeScript modernity — strict mode, module system, target

Quick Start

# Install as a dev dependency
npm install -D @vibgrate/cli@latest

# Run a scan
npx @vibgrate/cli scan

# Save a baseline
npx @vibgrate/cli baseline

Monorepo Support

Vibgrate automatically discovers all package.json files in your workspace. For pnpm workspaces, npm workspaces, or yarn workspaces, each package is scanned individually and the scores are aggregated.

# Scan an entire monorepo
vg scan /path/to/monorepo

# Exclude specific directories
# (configure in vibgrate.config.ts)

To exclude paths, add them to your vibgrate.config.ts:

import type { VibgrateConfig } from '@vibgrate/cli@latest';

const config: VibgrateConfig = {
  exclude: ['legacy/**', 'examples/**'],
};

export default config;

TypeScript Analysis

Vibgrate reads tsconfig.json to assess TypeScript modernity:

  • TypeScript version
  • strict, noImplicitAny, strictNullChecks flags
  • Module system (module, moduleResolution, target)
  • ESM vs CJS classification
  • exports field presence in package.json

Strict TypeScript configurations score higher in the modernity assessment.

Output Examples

# Human-readable report
vg scan --format text

# JSON artifact for automation
vg scan --format json --out scan.json

# Markdown for PRs or wikis
vg scan --format md --out drift-report.md

Next Steps

  • Set up CI integration to catch drift regression on every PR
  • Create a baseline to track improvements over time
  • Push results to the Vibgrate Cloud for portfolio visibility