@firebase/api-documenter 0.1.2-canary.233e117f0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +10 -0
- package/README.md +16 -0
- package/dist/cli/ApiDocumenterCommandLine.d.ts +22 -0
- package/dist/cli/ApiDocumenterCommandLine.js +44 -0
- package/dist/cli/ApiDocumenterCommandLine.js.map +1 -0
- package/dist/cli/BaseAction.d.ts +37 -0
- package/dist/cli/BaseAction.js +125 -0
- package/dist/cli/BaseAction.js.map +1 -0
- package/dist/cli/MarkdownAction.d.ts +22 -0
- package/dist/cli/MarkdownAction.js +47 -0
- package/dist/cli/MarkdownAction.js.map +1 -0
- package/dist/cli/TocAction.d.ts +25 -0
- package/dist/cli/TocAction.js +67 -0
- package/dist/cli/TocAction.js.map +1 -0
- package/dist/documenters/DocumenterConfig.d.ts +45 -0
- package/dist/documenters/DocumenterConfig.js +63 -0
- package/dist/documenters/DocumenterConfig.js.map +1 -0
- package/dist/documenters/IConfigFile.d.ts +98 -0
- package/dist/documenters/IConfigFile.js +19 -0
- package/dist/documenters/IConfigFile.js.map +1 -0
- package/dist/documenters/MarkdownDocumenter.d.ts +75 -0
- package/dist/documenters/MarkdownDocumenter.js +750 -0
- package/dist/documenters/MarkdownDocumenter.js.map +1 -0
- package/dist/documenters/MarkdownDocumenterHelpers.d.ts +40 -0
- package/dist/documenters/MarkdownDocumenterHelpers.js +306 -0
- package/dist/documenters/MarkdownDocumenterHelpers.js.map +1 -0
- package/dist/index.d.ts +27 -0
- package/dist/index.js +29 -0
- package/dist/index.js.map +1 -0
- package/dist/markdown/CustomMarkdownEmitter.d.ts +32 -0
- package/dist/markdown/CustomMarkdownEmitter.js +161 -0
- package/dist/markdown/CustomMarkdownEmitter.js.map +1 -0
- package/dist/markdown/MarkdownEmitter.d.ts +48 -0
- package/dist/markdown/MarkdownEmitter.js +243 -0
- package/dist/markdown/MarkdownEmitter.js.map +1 -0
- package/dist/markdown/test/CustomMarkdownEmitter.test.d.ts +17 -0
- package/dist/markdown/test/CustomMarkdownEmitter.test.js +205 -0
- package/dist/markdown/test/CustomMarkdownEmitter.test.js.map +1 -0
- package/dist/nodes/CustomDocNodeKind.d.ts +32 -0
- package/dist/nodes/CustomDocNodeKind.js +58 -0
- package/dist/nodes/CustomDocNodeKind.js.map +1 -0
- package/dist/nodes/DocEmphasisSpan.d.ts +35 -0
- package/dist/nodes/DocEmphasisSpan.js +39 -0
- package/dist/nodes/DocEmphasisSpan.js.map +1 -0
- package/dist/nodes/DocHeading.d.ts +38 -0
- package/dist/nodes/DocHeading.js +45 -0
- package/dist/nodes/DocHeading.js.map +1 -0
- package/dist/nodes/DocNoteBox.d.ts +33 -0
- package/dist/nodes/DocNoteBox.js +41 -0
- package/dist/nodes/DocNoteBox.js.map +1 -0
- package/dist/nodes/DocTable.d.ts +41 -0
- package/dist/nodes/DocTable.js +77 -0
- package/dist/nodes/DocTable.js.map +1 -0
- package/dist/nodes/DocTableCell.d.ts +31 -0
- package/dist/nodes/DocTableCell.js +37 -0
- package/dist/nodes/DocTableCell.js.map +1 -0
- package/dist/nodes/DocTableRow.d.ts +38 -0
- package/dist/nodes/DocTableRow.js +68 -0
- package/dist/nodes/DocTableRow.js.map +1 -0
- package/dist/plugin/IApiDocumenterPluginManifest.d.ts +85 -0
- package/dist/plugin/IApiDocumenterPluginManifest.js +19 -0
- package/dist/plugin/IApiDocumenterPluginManifest.js.map +1 -0
- package/dist/plugin/MarkdownDocumenterAccessor.d.ts +41 -0
- package/dist/plugin/MarkdownDocumenterAccessor.js +44 -0
- package/dist/plugin/MarkdownDocumenterAccessor.js.map +1 -0
- package/dist/plugin/MarkdownDocumenterFeature.d.ts +88 -0
- package/dist/plugin/MarkdownDocumenterFeature.js +66 -0
- package/dist/plugin/MarkdownDocumenterFeature.js.map +1 -0
- package/dist/plugin/PluginFeature.d.ts +61 -0
- package/dist/plugin/PluginFeature.js +76 -0
- package/dist/plugin/PluginFeature.js.map +1 -0
- package/dist/plugin/PluginLoader.d.ts +22 -0
- package/dist/plugin/PluginLoader.js +100 -0
- package/dist/plugin/PluginLoader.js.map +1 -0
- package/dist/schemas/api-documenter-template.json +92 -0
- package/dist/schemas/api-documenter.schema.json +42 -0
- package/dist/start.d.ts +18 -0
- package/dist/start.js +32 -0
- package/dist/start.js.map +1 -0
- package/dist/toc.d.ts +25 -0
- package/dist/toc.js +61 -0
- package/dist/toc.js.map +1 -0
- package/dist/utils/IndentedWriter.d.ts +116 -0
- package/dist/utils/IndentedWriter.js +213 -0
- package/dist/utils/IndentedWriter.js.map +1 -0
- package/dist/utils/Utilities.d.ts +28 -0
- package/dist/utils/Utilities.js +47 -0
- package/dist/utils/Utilities.js.map +1 -0
- package/dist/utils/test/IndentedWriter.test.d.ts +17 -0
- package/dist/utils/test/IndentedWriter.test.js +87 -0
- package/dist/utils/test/IndentedWriter.test.js.map +1 -0
- package/package.json +38 -0
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* @license
|
|
4
|
+
* Copyright 2020 Google LLC
|
|
5
|
+
*
|
|
6
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
|
+
* you may not use this file except in compliance with the License.
|
|
8
|
+
* You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
+
* See the License for the specific language governing permissions and
|
|
16
|
+
* limitations under the License.
|
|
17
|
+
*/
|
|
18
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
19
|
+
//# sourceMappingURL=IConfigFile.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IConfigFile.js","sourceRoot":"","sources":["../../src/documenters/IConfigFile.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;GAeG"}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { DocNode } from '@microsoft/tsdoc';
|
|
18
|
+
import { ApiModel, ApiItem } from 'api-extractor-model-me';
|
|
19
|
+
import { DocumenterConfig } from './DocumenterConfig';
|
|
20
|
+
export interface IMarkdownDocumenterOptions {
|
|
21
|
+
apiModel: ApiModel;
|
|
22
|
+
documenterConfig: DocumenterConfig | undefined;
|
|
23
|
+
outputFolder: string;
|
|
24
|
+
addFileNameSuffix: boolean;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Renders API documentation in the Markdown file format.
|
|
28
|
+
* For more info: https://en.wikipedia.org/wiki/Markdown
|
|
29
|
+
*/
|
|
30
|
+
export declare class MarkdownDocumenter {
|
|
31
|
+
private readonly _apiModel;
|
|
32
|
+
private readonly _documenterConfig;
|
|
33
|
+
private readonly _tsdocConfiguration;
|
|
34
|
+
private readonly _markdownEmitter;
|
|
35
|
+
private readonly _outputFolder;
|
|
36
|
+
private readonly _pluginLoader;
|
|
37
|
+
private readonly _addFileNameSuffix;
|
|
38
|
+
constructor(options: IMarkdownDocumenterOptions);
|
|
39
|
+
generateFiles(): void;
|
|
40
|
+
_writeApiItemPage(apiItem: ApiItem): void;
|
|
41
|
+
_createCompleteOutputForApiItem(apiItem: ApiItem): DocNode[];
|
|
42
|
+
/**
|
|
43
|
+
* GENERATE PAGE: CLASS
|
|
44
|
+
*
|
|
45
|
+
* TODO: generate member references in the same page
|
|
46
|
+
*/
|
|
47
|
+
private _createClassTables;
|
|
48
|
+
/**
|
|
49
|
+
* GENERATE PAGE: INTERFACE
|
|
50
|
+
*/
|
|
51
|
+
private _createInterfaceTables;
|
|
52
|
+
/**
|
|
53
|
+
* GENERATE PAGE: FUNCTION-LIKE
|
|
54
|
+
*/
|
|
55
|
+
private _createParameterTables;
|
|
56
|
+
private _createParagraphForTypeExcerpt;
|
|
57
|
+
private _appendExcerptWithHyperlinks;
|
|
58
|
+
/**
|
|
59
|
+
* GENERATE PAGE: MODEL
|
|
60
|
+
*/
|
|
61
|
+
private _createModelTable;
|
|
62
|
+
/**´
|
|
63
|
+
* Generate a table of entry points if there are more than one entry points.
|
|
64
|
+
* Otherwise, generate the entry point directly in the package page.
|
|
65
|
+
*/
|
|
66
|
+
private _createPackage;
|
|
67
|
+
/**
|
|
68
|
+
* GENERATE PAGE: ENTRYPOINT or NAMESPACE
|
|
69
|
+
*/
|
|
70
|
+
private _createEntryPointOrNamespace;
|
|
71
|
+
private _createPropertyTypeCell;
|
|
72
|
+
private _createSignatureSection;
|
|
73
|
+
private _writeHeritageTypes;
|
|
74
|
+
private _deleteOldOutputFiles;
|
|
75
|
+
}
|