Class Converter

Compiles source files using TypeScript and converts compiler symbols to reflections.

Hierarchy

  • ChildableComponent<Application, ConverterComponent>
    • Converter

Constructors

Properties

commentStyle: CommentStyle
componentName: string

The name of this component as set by the

Component

decorator.

excludeExternals: boolean
excludeNotDocumented: boolean
excludePrivate: boolean
excludeProtected: boolean
externalPattern: string[]
externalSymbolLinkMappings: Record<string, Record<string, string>>
validation: ValidationOptions

Events

EVENT_BEGIN: "begin" = ConverterEvents.BEGIN

Triggered when the converter begins converting a project. The listener will be given a Context object.

EVENT_CREATE_DECLARATION: "createDeclaration" = ConverterEvents.CREATE_DECLARATION

Triggered when the converter has created a declaration reflection. The listener will be given Context and a DeclarationReflection.

EVENT_CREATE_PARAMETER: "createParameter" = ConverterEvents.CREATE_PARAMETER

Triggered when the converter has created a parameter reflection. The listener will be given Context, ParameterReflection and a ts.Node?

EVENT_CREATE_SIGNATURE: "createSignature" = ConverterEvents.CREATE_SIGNATURE

Triggered when the converter has created a signature reflection. The listener will be given Context, SignatureReflection | ProjectReflection and ts.SignatureDeclaration | ts.IndexSignatureDeclaration | ts.JSDocSignature | undefined

EVENT_CREATE_TYPE_PARAMETER: "createTypeParameter" = ConverterEvents.CREATE_TYPE_PARAMETER

Triggered when the converter has created a type parameter reflection. The listener will be given Context and a TypeParameterReflection

EVENT_END: "end" = ConverterEvents.END

Triggered when the converter has finished converting a project. The listener will be given a Context object.

EVENT_RESOLVE: "resolveReflection" = ConverterEvents.RESOLVE

Triggered when the converter resolves a reflection. The listener will be given Context and a Reflection.

EVENT_RESOLVE_BEGIN: "resolveBegin" = ConverterEvents.RESOLVE_BEGIN

Triggered when the converter begins resolving a project. The listener will be given Context.

EVENT_RESOLVE_END: "resolveEnd" = ConverterEvents.RESOLVE_END

Triggered when the converter has finished resolving a project. The listener will be given Context.

Accessors

Methods

  • Type Parameters

    • T extends ConverterComponent<T>

    Parameters

    • name: string
    • componentClass: T | ComponentClass<T, Application>

    Returns T

  • Adds a new resolver that the theme can use to try to figure out how to link to a symbol declared by a third-party library which is not included in the documentation.

    The resolver function will be passed a declaration reference which it can attempt to resolve. If resolution fails, the function should return undefined.

    Note: This will be used for both references to types declared in node_modules (in which case the reference passed will have the moduleSource set and the symbolReference will navigate via .) and user defined {@link} tags which cannot be resolved.

    Since

    0.22.14

    Parameters

    Returns void

  • Internal

    Convert the given TypeScript type into its TypeDoc type reflection.

    Returns

    The TypeDoc type reflection representing the given node and type.

    Parameters

    • context: Context

      The context object describing the current state the converter is in.

    • node: undefined | TypeNode | Type

    Returns SomeType

  • Retrieve a plugin instance.

    Returns

    The instance of the plugin or undefined if no plugin with the given class is attached.

    Parameters

    • name: string

    Returns undefined | ConverterComponent

  • Returns ConverterComponent[]

  • Parameters

    • name: string

    Returns boolean

  • Bind an event to only be triggered a single time. After the first time the callback is invoked, its listener will be removed. If multiple events are passed in using the space-separated syntax, the handler will fire once for each event, not once for a combination of all events.

    Parameters

    • eventMap: EventMap
    • Optional context: any

    Returns Converter

  • Parameters

    • name: string
    • callback: EventCallback
    • Optional context: any
    • Optional priority: any

    Returns Converter

  • Parameters

    • name: string

    Returns undefined | ConverterComponent

  • Internal

    Used to determine if we should immediately bail when creating a reflection. Note: This should not be used for excludeNotDocumented because we don't have enough information at this point since comment discovery hasn't happened.

    Parameters

    • symbol: Symbol

    Returns boolean

  • Trigger one or many events, firing all bound callbacks. Callbacks are passed the same arguments as trigger is, apart from the event name (unless you're listening on "all", which will cause your callback to receive the true name of the event as the first argument).

    Parameters

    Returns Converter

Generated using TypeDoc