如何创建仅记录通过index.ts公开的对象的Typedoc?

时间:2019-02-18 09:14:24

标签: documentation typedoc

我正在创建一个以click作为入口点的NPM软件包。

index.js(编译为index.ts)仅导出类index.js

但typedoc记录了其他类,这些类未公开给用户,但仅由Client内部使用。

这是此类模块的示例。我相信我正在编写的npm包没有暴露它,但是我仍然导出模块,以便Client模块可以使用它。

Client

如何从我的typedoc文档中清除这些类?

我只希望创建使用此类的客户端方法import { Connection } from '../connection'; import { Request, IRequestBody } from '.'; import { IServerResponse } from '../common'; export interface RecordingDeleteRequestBody extends IRequestBody { cmd: 'recording_delete'; data: { recording_id: number; } } export interface RecordingDeleteServerResponse extends IServerResponse { cmd: 'recording_delete'; } export type RecordingDeleteResponse = true; export class RecordingDeleteRequest extends Request { constructor( recordingId: number, transactionId: string, connection: Connection, maxTime: number ) { let requestBody: RecordingDeleteRequestBody = { type: 'request', cmd: 'recording_delete', data: { recording_id: recordingId } } super(requestBody, transactionId, connection, maxTime); } async run(): Promise<RecordingDeleteResponse> { await new Promise<RecordingDeleteServerResponse>((resolve, reject) => { this.connection.push( this.requestBody, this.transactionId, this.maxTime, resolve, reject ); }); return true; } } 的文档。

Class.recordingDeleteRequest()

1 个答案:

答案 0 :(得分:1)

TypeDoc尚不仅支持记录导出的符号(请参见issue #639)。 @ignore文档注释可用于手动隐藏单个符号。