1 | {
|
2 | "$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
|
3 |
|
4 | /**
|
5 | * (REQUIRED) Specifies the .d.ts file to be used as the starting point for analysis. API Extractor
|
6 | * analyzes the symbols exported by this module.
|
7 | *
|
8 | * The file extension must be ".d.ts" and not ".ts".
|
9 | * The path is resolved relative to the "rootFolder" location described below.
|
10 | */
|
11 | "mainEntryPointFilePath": "<projectFolder>/dist/index.d.ts",
|
12 |
|
13 | /**
|
14 | * Determines how the TypeScript compiler engine will be invoked by API Extractor.
|
15 | */
|
16 |
|
17 | "compiler": {},
|
18 |
|
19 | /**
|
20 | * Configures how the API report file (*.api.md) will be generated.
|
21 | */
|
22 | "apiReport": {
|
23 | "enabled": false,
|
24 | "reportFileName": "<unscopedPackageName>.api.md",
|
25 | "reportFolder": "<projectFolder>/_api-review/",
|
26 | "reportTempFolder": "<projectFolder>/_api-extractor-temp/"
|
27 | },
|
28 |
|
29 | /**
|
30 | * Configures how the doc model file (*.api.json) will be generated.
|
31 | */
|
32 | "docModel": {
|
33 | "enabled": true,
|
34 | "apiJsonFilePath": "<projectFolder>/_api-extractor-temp/doc-models/<unscopedPackageName>.api.json"
|
35 | },
|
36 |
|
37 | /**
|
38 | * Configures how the .d.ts rollup file will be generated.
|
39 | */
|
40 | "dtsRollup": {
|
41 | "enabled": false,
|
42 | "untrimmedFilePath": "<projectFolder>/dist/<unscopedPackageName>.d.ts",
|
43 | "betaTrimmedFilePath": "<projectFolder>/dist/<unscopedPackageName>-beta.d.ts",
|
44 | "publicTrimmedFilePath": "<projectFolder>/dist/<unscopedPackageName>-public.d.ts"
|
45 | },
|
46 |
|
47 | /**
|
48 | * Configures how the tsdoc-metadata.json file will be generated.
|
49 | */
|
50 | "tsdocMetadata": {
|
51 | "enabled": true
|
52 | },
|
53 |
|
54 | /**
|
55 | * Configures how API Extractor reports error and warning messages produced during analysis.
|
56 | *
|
57 | * There are three sources of messages: compiler messages, API Extractor messages, and TSDoc messages.
|
58 | */
|
59 | "messages": {
|
60 | /**
|
61 | * Configures handling of diagnostic messages reported by the TypeScript compiler engine while analyzing
|
62 | * the input .d.ts files.
|
63 | *
|
64 | * TypeScript message identifiers start with "TS" followed by an integer. For example: "TS2551"
|
65 | *
|
66 | * DEFAULT VALUE: A single "default" entry with logLevel=warning.
|
67 | */
|
68 | "compilerMessageReporting": {
|
69 | /**
|
70 | * Configures the default routing for messages that don't match an explicit rule in this table.
|
71 | */
|
72 | "default": {
|
73 | /**
|
74 | * Specifies whether the message should be written to the the tool's output log. Note that
|
75 | * the "addToApiReviewFile" property may supersede this option.
|
76 | *
|
77 | * Possible values: "error", "warning", "none"
|
78 | *
|
79 | * Errors cause the build to fail and return a nonzero exit code. Warnings cause a production build fail
|
80 | * and return a nonzero exit code. For a non-production build (e.g. when "api-extractor run" includes
|
81 | * the "--local" option), the warning is displayed but the build will not fail.
|
82 | *
|
83 | * DEFAULT VALUE: "warning"
|
84 | */
|
85 | "logLevel": "error"
|
86 | /**
|
87 | * When addToApiReviewFile is true: If API Extractor is configured to write an API report file (.api.md),
|
88 | * then the message will be written inside that file; otherwise, the message is instead logged according to
|
89 | * the "logLevel" option.
|
90 | *
|
91 | * DEFAULT VALUE: false
|
92 | */
|
93 | // "addToApiReviewFile": false
|
94 | }
|
95 |
|
96 | // "TS2551": {
|
97 | // "logLevel": "warning",
|
98 | // "addToApiReviewFile": true
|
99 | // },
|
100 | //
|
101 | // . . .
|
102 | },
|
103 |
|
104 | /**
|
105 | * Configures handling of messages reported by API Extractor during its analysis.
|
106 | *
|
107 | * API Extractor message identifiers start with "ae-". For example: "ae-extra-release-tag"
|
108 | *
|
109 | * DEFAULT VALUE: See api-extractor-defaults.json for the complete table of extractorMessageReporting mappings
|
110 | */
|
111 | "extractorMessageReporting": {
|
112 | "default": {
|
113 | "logLevel": "error"
|
114 | // "addToApiReviewFile": false
|
115 | },
|
116 | "ae-forgotten-export": {
|
117 | "logLevel": "error"
|
118 | },
|
119 | "ae-extra-release-tag": {
|
120 | "logLevel": "warning"
|
121 | },
|
122 | "ae-missing-release-tag": {
|
123 | "logLevel": "none"
|
124 | },
|
125 | "ae-unresolved-inheritdoc-reference": {
|
126 | "logLevel": "error"
|
127 | }
|
128 | },
|
129 |
|
130 | /**
|
131 | * Configures handling of messages reported by the TSDoc parser when analyzing code comments.
|
132 | *
|
133 | * TSDoc message identifiers start with "tsdoc-". For example: "tsdoc-link-tag-unescaped-text"
|
134 | *
|
135 | * DEFAULT VALUE: A single "default" entry with logLevel=warning.
|
136 | */
|
137 | "tsdocMessageReporting": {
|
138 | "default": {
|
139 | "logLevel": "error"
|
140 | }
|
141 |
|
142 | // "tsdoc-link-tag-unescaped-text": {
|
143 | // "logLevel": "warning",
|
144 | // "addToApiReviewFile": true
|
145 | // },
|
146 | //
|
147 | // . . .
|
148 | }
|
149 | }
|
150 | }
|