1.1.0 • Published 9 months ago

import-content-collector v1.1.0

Weekly downloads
-
License
MIT
Repository
-
Last release
9 months ago

Import Content Collector

A CLI tool that collects and combines the content of a TypeScript/JavaScript file along with all its local imports into a single output file. Perfect for sharing code snippets or creating self-contained examples.

Features

  • Collects content from the main file and all its local imports
  • Supports TypeScript and JavaScript files
  • Handles both ES6 imports and CommonJS requires
  • Supports JSX and TypeScript decorators
  • Prevents duplicate processing of files
  • Generates a well-formatted output with file headers

Installation

npm install -g import-content-collector

Usage

Command Line

import-collect <source-file> [-o output-file]

Options:

  • <source-file>: Path to the source file (required)
  • -o, --output: Output file name (default: "collected-content.txt")

Example:

import-collect src/index.ts -o combined.txt
1.1.0

9 months ago

1.0.9

9 months ago

1.0.8

9 months ago

1.0.7

9 months ago

1.0.6

9 months ago

1.0.5

9 months ago

1.0.3

9 months ago

1.0.2

9 months ago

1.0.1

9 months ago

1.0.0

9 months ago