Nanotech Parading Mars

    typedoc-plugin-inline-sources
    TypeScript icon, indicating that this package has built-in type declarations

    1.0.1 • Public • Published

    typedoc-plugin-inline-sources

    A plugin for TypeDoc that inlines source code into comments.

    npm CI

    What it does?

    The plugin retrieves the source from the ts compiler and injects within fenced code blocks.

    Installation

    npm install --save-dev typedoc typedoc-plugin-inline-sources

    Usage

    Simply use the @source annotation in your comments. This will create a tag with the inlined source code.

    Code

    /**
     * Comments for variable
     *
     * @source source tag comment?
     */
    export const message = 'Hello World!';

    Model

    Comment {
      tags: [
        {
          tagName: 'source',
          text: 'source tag comment?\n' +
            '\n' +
            '```typescript\n' +
            'export const message = "Hello World!";\n' +
            '```\n' +
            '\n'
        }
      ],
      shortText: 'Comments for variable',
    }
    

    Output (default theme)

    image

    Install

    npm i typedoc-plugin-inline-sources

    DownloadsWeekly Downloads

    217

    Version

    1.0.1

    License

    MIT

    Unpacked Size

    6 kB

    Total Files

    6

    Last publish

    Collaborators

    • tgreyuk