open-index/open-npm huggingface dataset:
npm package: @opexa/vite-plugin-screenshot
Description: Take a screenshot of your Vite application during build.
Latest version: 0.0.2

# Vite Screenshot Plugin

Take a screenshot of your Vite application during build.

## Installation

```bash
npm install --save-dev @opexa/vite-plugin-screenshot
```

## Usage

```ts
// vite.config.ts
import { defineConfig } from 'vite';
import { screenshot } from '@opexa/vite-plugin-screenshot';

export default defineConfig({
  plugins: [
    screenshot({
      width: 1000,
      height: 1080,
      filePath: 'static/screenshot',
      fileType: 'webp',
      quality: 80,
      fullPage: true,
    }),
  ],
});
```
npm package: @ophan/cli
Description: AI-powered security analysis and documentation for your codebase. Detects vulnerabilities, maps data flows, and auto-documents every function — from the command line.
Latest version: 0.0.7

# @ophan/cli

AI-powered security analysis and documentation for your codebase. Detects vulnerabilities, maps data flows, and auto-documents every function — from the command line.

Part of [Ophan](https://ophan.dev). Works standalone or alongside the [VS Code extension](https://marketplace.visualstudio.com/items?itemName=ophan.ophan).

## Quick Start

```bash
npx @ophan/cli analyze
```

That's it. Ophan scans your repo, extracts every function, and sends them to Claude for security analysis and documentation. Results are stored locally in `.ophan/index.db`.

You'll need an [Anthropic API key](https://console.anthropic.com/) set as `ANTHROPIC_API_KEY` in your environment or a `.env` file.

## What You Get

For every function in your codebase:

- **Security analysis** — SQL injection, XSS, hardcoded secrets, path traversal, unsanitized input
- **Data flow tags** — which functions touch user input, PII, credentials, databases, external APIs
- **Documentation** — plain-English descriptions, parameter docs, return type docs

## Commands

```bash
npx @ophan/cli analyze          # Analyze current directory
npx @ophan/cli analyze --path . # Analyze a specific path
npx @ophan/cli sync             # Sync results to ophan.dev (optional)
npx @ophan/cli gc               # Clean up old analysis entries
```

### As a dev dependency

```bash
npm install --save-dev @ophan/cli
npx @ophan/cli analyze
```

Add to your team's repo so everyone gets the CLI on `npm install`. Analysis is cached by content hash — unchanged functions are never re-analyzed.

## How It Works

1. Parses your source files using language-native ASTs (TypeScript compiler API, Python's `ast` module)
2. Extracts every function and computes a SHA256 content hash
3. Skips functions that haven't changed since last analysis
4. Sends new/changed functions to Claude for security and documentation analysis
5. Stores results locally in `.ophan/index.db` (gitignored)

Supports **TypeScript**, **JavaScript**, and **Python**.

## Cloud Sync

Optionally sync your analysis to [ophan.dev](https://ophan.dev) for a web dashboard, team sharing, and cross-machine access.

```bash
npx @ophan/cli login             # Authenticate with ophan.dev
npx @ophan/cli analyze           # Auto-pulls from cloud, then analyzes remaining
npx @ophan/cli sync              # Push new results to cloud
```

## Resources

- [Documentation](https://docs.ophan.dev)
- [CLI Reference](https://docs.ophan.dev/cli/commands)
- [VS Code Extension](https://marketplace.visualstudio.com/items?itemName=ophan.ophan)
- [GitHub](https://github.com/nicholasgriffintn/ophan)

## License

MIT
npm package: @ophan/core
Description: The analysis engine behind [Ophan](https://ophan.dev) — AI-powered security analysis and documentation for codebases.
Latest version: 0.0.7

# @ophan/core

The analysis engine behind [Ophan](https://ophan.dev) — AI-powered security analysis and documentation for codebases.

This package provides the core analysis pipeline: source code parsing, function extraction, Claude-powered security analysis, and local SQLite storage. Used by [`@ophan/cli`](https://www.npmjs.com/package/@ophan/cli) and the [Ophan VS Code extension](https://marketplace.visualstudio.com/items?itemName=ophan.ophan).

## What It Does

- **Parses source code** using language-native ASTs (TypeScript compiler API, Python's `ast` module)
- **Extracts functions** and computes SHA256 content hashes for change detection
- **Analyzes with Claude** to detect security vulnerabilities and generate documentation
- **Stores results** in a local SQLite database, keyed by content hash

### Security Detection

Identifies vulnerabilities including SQL injection, XSS, hardcoded secrets, path traversal, insecure deserialization, and unsanitized user input.

### Data Flow Classification

Tags functions by the data they handle: user input, PII, credentials, database operations, external APIs, file system access, and more.

### Auto-Documentation

Generates plain-English descriptions, parameter documentation, and return type documentation for every function.

## Supported Languages

| Language | Parser | Extensions |
|----------|--------|------------|
| TypeScript | TypeScript compiler API | `.ts`, `.tsx` |
| JavaScript | TypeScript compiler API | `.js`, `.jsx` |
| Python | Python `ast` module | `.py` |

## Usage

Most users should use [`@ophan/cli`](https://www.npmjs.com/package/@ophan/cli) or the [VS Code extension](https://marketplace.visualstudio.com/items?itemName=ophan.ophan) instead of importing this package directly.

`@ophan/core` is published for tools that need to build on the Ophan analysis pipeline programmatically.

```typescript
import { analyzeRepository, initDb } from '@ophan/core';

const db = initDb('/path/to/repo');
await analyzeRepository(db, '/path/to/repo', {
  apiKey: process.env.ANTHROPIC_API_KEY,
});
```

### Schemas

Zod schemas and TypeScript types for Ophan's analysis data are available as a lightweight subpath import — no native dependencies required:

```typescript
import {
  ClaudeAnalysisResponse,
  SECURITY_FLAG_LABELS,
  DATA_TAG_LABELS,
} from '@ophan/core/schemas';
```

## Resources

- [Documentation](https://docs.ophan.dev)
- [CLI Package](https://www.npmjs.com/package/@ophan/cli)
- [VS Code Extension](https://marketplace.visualstudio.com/items?itemName=ophan.ophan)
- [GitHub](https://github.com/nicholasgriffintn/ophan)

## License

MIT