ts-to-md
TypeScript icon, indicating that this package has built-in type declarations

0.2.0 • Public • Published

TypeScript to Markdown

Given a TS file, generate markdown documentation for all it's exports.

pnpm i ts-to-md

See API.md for an example output.

Usage

CLI

ts-to-md -i src/index.ts -o docs/index.md

See ts-to-md --help for more a list of options.

Node API

import { generate } from 'ts-to-md';

const markdown = generate({ inputFile: './index.ts' });

Development

pnpm i

All testing is done via simple E2E tests. To run them, run:

pnpm test

To create a test case, create two files:

  1. {test-name}.input.ts - This is the input file being checked
  2. {test-name}.output.md - This defines the expected output

Package Sidebar

Install

npm i ts-to-md

Weekly Downloads

1

Version

0.2.0

License

MIT

Unpacked Size

33.4 kB

Total Files

10

Last publish

Collaborators

  • _aklinker1