@microsoft/api-extractor 7.52.2 → 7.52.3

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.json CHANGED
@@ -1,6 +1,18 @@
1
1
  {
2
2
  "name": "@microsoft/api-extractor",
3
3
  "entries": [
4
+ {
5
+ "version": "7.52.3",
6
+ "tag": "@microsoft/api-extractor_v7.52.3",
7
+ "date": "Fri, 04 Apr 2025 18:34:35 GMT",
8
+ "comments": {
9
+ "patch": [
10
+ {
11
+ "comment": "Add support for customizing which TSDoc tags appear in API reports"
12
+ }
13
+ ]
14
+ }
15
+ },
4
16
  {
5
17
  "version": "7.52.2",
6
18
  "tag": "@microsoft/api-extractor_v7.52.2",
package/CHANGELOG.md CHANGED
@@ -1,6 +1,13 @@
1
1
  # Change Log - @microsoft/api-extractor
2
2
 
3
- This log was last generated on Tue, 25 Mar 2025 15:11:15 GMT and should not be manually modified.
3
+ This log was last generated on Fri, 04 Apr 2025 18:34:35 GMT and should not be manually modified.
4
+
5
+ ## 7.52.3
6
+ Fri, 04 Apr 2025 18:34:35 GMT
7
+
8
+ ### Patches
9
+
10
+ - Add support for customizing which TSDoc tags appear in API reports
4
11
 
5
12
  ## 7.52.2
6
13
  Tue, 25 Mar 2025 15:11:15 GMT
package/dist/rollup.d.ts CHANGED
@@ -227,6 +227,8 @@ export declare class ExtractorConfig {
227
227
  readonly reportFolder: string;
228
228
  /** {@inheritDoc IConfigApiReport.reportTempFolder} */
229
229
  readonly reportTempFolder: string;
230
+ /** {@inheritDoc IConfigApiReport.tagsToReport} */
231
+ readonly tagsToReport: Readonly<Record<`@${string}`, boolean>>;
230
232
  /**
231
233
  * Gets the file path for the "complete" (default) report configuration, if one was specified.
232
234
  * Otherwise, returns an empty string.
@@ -785,6 +787,40 @@ export declare interface IConfigApiReport {
785
787
  * @defaultValue `false`
786
788
  */
787
789
  includeForgottenExports?: boolean;
790
+ /**
791
+ * Specifies a list of {@link https://tsdoc.org/ | TSDoc} tags that should be reported in the API report file for
792
+ * items whose documentation contains them.
793
+ *
794
+ * @remarks
795
+ * Tag names must begin with `@`.
796
+ *
797
+ * This list may include standard TSDoc tags as well as custom ones.
798
+ * For more information on defining custom TSDoc tags, see
799
+ * {@link https://api-extractor.com/pages/configs/tsdoc_json/#defining-your-own-tsdoc-tags | here}.
800
+ *
801
+ * Note that an item's release tag will always reported; this behavior cannot be overridden.
802
+ *
803
+ * @defaultValue `@sealed`, `@virtual`, `@override`, `@eventProperty`, and `@deprecated`
804
+ *
805
+ * @example Omitting default tags
806
+ * To omit the `@sealed` and `@virtual` tags from API reports, you would specify `tagsToReport` as follows:
807
+ * ```json
808
+ * "tagsToReport": {
809
+ * "@sealed": false,
810
+ * "@virtual": false
811
+ * }
812
+ * ```
813
+ *
814
+ * @example Including additional tags
815
+ * To include additional tags to the set included in API reports, you could specify `tagsToReport` like this:
816
+ * ```json
817
+ * "tagsToReport": {
818
+ * "@customTag": true
819
+ * }
820
+ * ```
821
+ * This will result in `@customTag` being included in addition to the default tags.
822
+ */
823
+ tagsToReport?: Readonly<Record<`@${string}`, boolean>>;
788
824
  }
789
825
 
790
826
  /**
@@ -163,6 +163,8 @@ export declare class ExtractorConfig {
163
163
  readonly reportFolder: string;
164
164
  /** {@inheritDoc IConfigApiReport.reportTempFolder} */
165
165
  readonly reportTempFolder: string;
166
+ /** {@inheritDoc IConfigApiReport.tagsToReport} */
167
+ readonly tagsToReport: Readonly<Record<`@${string}`, boolean>>;
166
168
  /**
167
169
  * Gets the file path for the "complete" (default) report configuration, if one was specified.
168
170
  * Otherwise, returns an empty string.
@@ -1 +1 @@
1
- {"version":3,"file":"ExtractorConfig.d.ts","sourceRoot":"","sources":["../../src/api/ExtractorConfig.ts"],"names":[],"mappings":"AAMA,OAAO,EAEL,UAAU,EAEV,iBAAiB,EACjB,KAAK,gBAAgB,EAKrB,WAAW,EACZ,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,KAAK,UAAU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AAC;IAE9C;;OAEG;IACH,SAAgB,eAAe,EAAE,eAAe,CAAC;IAEjD;;OAEG;IACH,SAAgB,kBAAkB,EAAE,kBAAkB,CAAC;IAEvD;;;OAGG;IACH,SAAgB,WAAW,EAAE,WAAW,CAAC;IAEzC,yCAAyC;IACzC,SAAgB,QAAQ,EAAE,wBAAwB,CAAC;IAEnD,yCAAyC;IACzC,SAAgB,QAAQ,EAAE,OAAO,CAAC;IAElC,gDAAgD;IAChD,SAAgB,eAAe,EAAE,eAAe,CAAC;IAEjD,OAAO;IAoEP;;;;;;;OAOG;IACI,iBAAiB,IAAI,MAAM;IAiBlC;;;OAGG;IACI,iBAAiB,CAAC,YAAY,EAAE,MAAM,GAAG,MAAM;IAUtD;;;;;;;;;;;;;;;;;OAiBG;WACW,gBAAgB,CAC5B,OAAO,EAAE,oCAAoC,GAC5C,8BAA8B,GAAG,SAAS;IA6E7C;;;;;;;;OAQG;WACW,kBAAkB,CAAC,kBAAkB,EAAE,MAAM,GAAG,eAAe;IAiB7E;;;;;;;OAOG;WACW,QAAQ,CAAC,YAAY,EAAE,MAAM,GAAG,WAAW;IAoFzD,OAAO,CAAC,MAAM,CAAC,+BAA+B;IAmG9C,OAAO,CAAC,MAAM,CAAC,8BAA8B;IAgB7C;;;;OAIG;WACW,OAAO,CAAC,OAAO,EAAE,8BAA8B,GAAG,eAAe;IAsc/E;;OAEG;IACH,OAAO,CAAC,wBAAwB;IAIhC,OAAO,CAAC,MAAM,CAAC,sBAAsB;IAYrC,OAAO,CAAC,MAAM,CAAC,uBAAuB;IAgCtC;;OAEG;WACW,mBAAmB,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO;IAI5D;;;OAGG;IACH,OAAO,CAAC,MAAM,CAAC,sBAAsB;CAatC"}
@@ -50,6 +50,23 @@ const tsdoc_config_1 = require("@microsoft/tsdoc-config");
50
50
  const PackageMetadataManager_1 = require("../analyzer/PackageMetadataManager");
51
51
  const MessageRouter_1 = require("../collector/MessageRouter");
52
52
  const api_extractor_schema_json_1 = __importDefault(require("../schemas/api-extractor.schema.json"));
53
+ /** Default {@link IConfigApiReport.reportVariants} */
54
+ const defaultApiReportVariants = ['complete'];
55
+ /**
56
+ * Default {@link IConfigApiReport.tagsToReport}.
57
+ *
58
+ * @remarks
59
+ * Note that this list is externally documented, and directly affects report output.
60
+ * Also note that the order of tags in this list is significant, as it determines the order of tags in the report.
61
+ * Any changes to this list should be considered breaking.
62
+ */
63
+ const defaultTagsToReport = {
64
+ '@sealed': true,
65
+ '@virtual': true,
66
+ '@override': true,
67
+ '@eventProperty': true,
68
+ '@deprecated': true
69
+ };
53
70
  /**
54
71
  * The `ExtractorConfig` class loads, validates, interprets, and represents the api-extractor.json config file.
55
72
  * @sealed
@@ -74,7 +91,7 @@ class ExtractorConfig {
74
91
  const completeConfig = this._getCompleteReportConfig();
75
92
  return completeConfig === undefined ? '' : path.join(this.reportTempFolder, completeConfig.fileName);
76
93
  }
77
- constructor({ projectFolder, packageJson, packageFolder, mainEntryPointFilePath, bundledPackages, tsconfigFilePath, overrideTsconfig, skipLibCheck, apiReportEnabled, apiReportIncludeForgottenExports, reportConfigs, reportFolder, reportTempFolder, docModelGenerationOptions, apiJsonFilePath, docModelIncludeForgottenExports, projectFolderUrl, rollupEnabled, untrimmedFilePath, alphaTrimmedFilePath, betaTrimmedFilePath, publicTrimmedFilePath, omitTrimmingComments, tsdocMetadataEnabled, tsdocMetadataFilePath, tsdocConfigFile, tsdocConfiguration, newlineKind, messages, testMode, enumMemberOrder }) {
94
+ constructor({ projectFolder, packageJson, packageFolder, mainEntryPointFilePath, bundledPackages, tsconfigFilePath, overrideTsconfig, skipLibCheck, apiReportEnabled, apiReportIncludeForgottenExports, reportConfigs, reportFolder, reportTempFolder, tagsToReport, docModelGenerationOptions, apiJsonFilePath, docModelIncludeForgottenExports, projectFolderUrl, rollupEnabled, untrimmedFilePath, alphaTrimmedFilePath, betaTrimmedFilePath, publicTrimmedFilePath, omitTrimmingComments, tsdocMetadataEnabled, tsdocMetadataFilePath, tsdocConfigFile, tsdocConfiguration, newlineKind, messages, testMode, enumMemberOrder }) {
78
95
  this.projectFolder = projectFolder;
79
96
  this.packageJson = packageJson;
80
97
  this.packageFolder = packageFolder;
@@ -88,6 +105,7 @@ class ExtractorConfig {
88
105
  this.reportConfigs = reportConfigs;
89
106
  this.reportFolder = reportFolder;
90
107
  this.reportTempFolder = reportTempFolder;
108
+ this.tagsToReport = tagsToReport;
91
109
  this.docModelGenerationOptions = docModelGenerationOptions;
92
110
  this.apiJsonFilePath = apiJsonFilePath;
93
111
  this.docModelIncludeForgottenExports = docModelIncludeForgottenExports;
@@ -381,7 +399,7 @@ class ExtractorConfig {
381
399
  * loaded from an alternate source, and/or customized after loading.
382
400
  */
383
401
  static prepare(options) {
384
- var _a, _b, _c, _d, _e, _f, _g;
402
+ var _a, _b, _c, _d, _e, _f, _g, _h;
385
403
  const filenameForErrors = options.configObjectFullPath || 'the configuration object';
386
404
  const configObject = options.configObject;
387
405
  if (configObject.extends) {
@@ -499,11 +517,15 @@ class ExtractorConfig {
499
517
  throw new Error('The file referenced by "tsconfigFilePath" does not exist: ' + tsconfigFilePath);
500
518
  }
501
519
  }
502
- const apiReportEnabled = (_b = (_a = configObject.apiReport) === null || _a === void 0 ? void 0 : _a.enabled) !== null && _b !== void 0 ? _b : false;
503
- const apiReportIncludeForgottenExports = (_d = (_c = configObject.apiReport) === null || _c === void 0 ? void 0 : _c.includeForgottenExports) !== null && _d !== void 0 ? _d : false;
520
+ if ((_a = configObject.apiReport) === null || _a === void 0 ? void 0 : _a.tagsToReport) {
521
+ _validateTagsToReport(configObject.apiReport.tagsToReport);
522
+ }
523
+ const apiReportEnabled = (_c = (_b = configObject.apiReport) === null || _b === void 0 ? void 0 : _b.enabled) !== null && _c !== void 0 ? _c : false;
524
+ const apiReportIncludeForgottenExports = (_e = (_d = configObject.apiReport) === null || _d === void 0 ? void 0 : _d.includeForgottenExports) !== null && _e !== void 0 ? _e : false;
504
525
  let reportFolder = tokenContext.projectFolder;
505
526
  let reportTempFolder = tokenContext.projectFolder;
506
527
  const reportConfigs = [];
528
+ let tagsToReport = {};
507
529
  if (apiReportEnabled) {
508
530
  // Undefined case checked above where we assign `apiReportEnabled`
509
531
  const apiReportConfig = configObject.apiReport;
@@ -531,7 +553,7 @@ class ExtractorConfig {
531
553
  // Default value
532
554
  reportFileNameBase = '<unscopedPackageName>';
533
555
  }
534
- const reportVariantKinds = (_e = apiReportConfig.reportVariants) !== null && _e !== void 0 ? _e : ['complete'];
556
+ const reportVariantKinds = (_f = apiReportConfig.reportVariants) !== null && _f !== void 0 ? _f : defaultApiReportVariants;
535
557
  for (const reportVariantKind of reportVariantKinds) {
536
558
  // Omit the variant kind from the "complete" report file name for simplicity and for backwards compatibility.
537
559
  const fileNameWithTokens = `${reportFileNameBase}${reportVariantKind === 'complete' ? '' : `.${reportVariantKind}`}${reportFileNameSuffix}`;
@@ -547,12 +569,13 @@ class ExtractorConfig {
547
569
  if (apiReportConfig.reportTempFolder) {
548
570
  reportTempFolder = ExtractorConfig._resolvePathWithTokens('reportTempFolder', apiReportConfig.reportTempFolder, tokenContext);
549
571
  }
572
+ tagsToReport = Object.assign(Object.assign({}, defaultTagsToReport), apiReportConfig.tagsToReport);
550
573
  }
551
574
  let docModelGenerationOptions = undefined;
552
575
  let apiJsonFilePath = '';
553
576
  let docModelIncludeForgottenExports = false;
554
577
  let projectFolderUrl;
555
- if ((_f = configObject.docModel) === null || _f === void 0 ? void 0 : _f.enabled) {
578
+ if ((_g = configObject.docModel) === null || _g === void 0 ? void 0 : _g.enabled) {
556
579
  apiJsonFilePath = ExtractorConfig._resolvePathWithTokens('apiJsonFilePath', configObject.docModel.apiJsonFilePath, tokenContext);
557
580
  docModelIncludeForgottenExports = !!configObject.docModel.includeForgottenExports;
558
581
  projectFolderUrl = configObject.docModel.projectFolderUrl;
@@ -639,7 +662,7 @@ class ExtractorConfig {
639
662
  newlineKind = node_core_library_1.NewlineKind.CrLf;
640
663
  break;
641
664
  }
642
- const enumMemberOrder = (_g = configObject.enumMemberOrder) !== null && _g !== void 0 ? _g : api_extractor_model_1.EnumMemberOrder.ByName;
665
+ const enumMemberOrder = (_h = configObject.enumMemberOrder) !== null && _h !== void 0 ? _h : api_extractor_model_1.EnumMemberOrder.ByName;
643
666
  extractorConfigParameters = {
644
667
  projectFolder: projectFolder,
645
668
  packageJson,
@@ -654,6 +677,7 @@ class ExtractorConfig {
654
677
  reportFolder,
655
678
  reportTempFolder,
656
679
  apiReportIncludeForgottenExports,
680
+ tagsToReport,
657
681
  docModelGenerationOptions,
658
682
  apiJsonFilePath,
659
683
  docModelIncludeForgottenExports,
@@ -776,4 +800,40 @@ ExtractorConfig._tsdocBaseFilePath = path.resolve(__dirname, '../../extends/tsdo
776
800
  ExtractorConfig._defaultConfig = node_core_library_1.JsonFile.load(path.join(__dirname, '../schemas/api-extractor-defaults.json'));
777
801
  /** Match all three flavors for type declaration files (.d.ts, .d.mts, .d.cts) */
778
802
  ExtractorConfig._declarationFileExtensionRegExp = /\.d\.(c|m)?ts$/i;
803
+ const releaseTags = new Set(['@public', '@alpha', '@beta', '@internal']);
804
+ /**
805
+ * Validate {@link ExtractorConfig.tagsToReport}.
806
+ */
807
+ function _validateTagsToReport(tagsToReport) {
808
+ const includedReleaseTags = [];
809
+ const invalidTags = []; // tag name, error
810
+ for (const tag of Object.keys(tagsToReport)) {
811
+ if (releaseTags.has(tag)) {
812
+ // If a release tags is specified, regardless of whether it is enabled, we will throw an error.
813
+ // Release tags must not be specified.
814
+ includedReleaseTags.push(tag);
815
+ }
816
+ // If the tag is invalid, generate an error string from the inner error message.
817
+ try {
818
+ tsdoc_1.TSDocTagDefinition.validateTSDocTagName(tag);
819
+ }
820
+ catch (error) {
821
+ invalidTags.push([tag, error.message]);
822
+ }
823
+ }
824
+ const errorMessages = [];
825
+ for (const includedReleaseTag of includedReleaseTags) {
826
+ errorMessages.push(`${includedReleaseTag}: Release tags are always included in API reports and must not be specified`);
827
+ }
828
+ for (const [invalidTag, innerError] of invalidTags) {
829
+ errorMessages.push(`${invalidTag}: ${innerError}`);
830
+ }
831
+ if (errorMessages.length > 0) {
832
+ const errorMessage = [
833
+ `"tagsToReport" contained one or more invalid tags:`,
834
+ ...errorMessages
835
+ ].join('\n\t- ');
836
+ throw new Error(errorMessage);
837
+ }
838
+ }
779
839
  //# sourceMappingURL=ExtractorConfig.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ExtractorConfig.js","sourceRoot":"","sources":["../../src/api/ExtractorConfig.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAE3D,2CAA6B;AAC7B,iDAAmC;AACnC,iCAAkC;AAClC,oEAWsC;AACtC,wDAAoE;AACpE,wEAA6E;AAC7E,4CAAsD;AACtD,0DAA0D;AAQ1D,+EAA4E;AAC5E,8DAA2D;AAG3D,qGAAsE;AAgLtE;;;;GAIG;AACH,MAAa,eAAe;IAuE1B;;;;OAIG;IACH,IAAW,cAAc;QACvB,MAAM,cAAc,GAA0C,IAAI,CAAC,wBAAwB,EAAE,CAAC;QAC9F,OAAO,cAAc,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,YAAY,EAAE,cAAc,CAAC,QAAQ,CAAC,CAAC;IACnG,CAAC;IAED;;;;OAIG;IACH,IAAW,kBAAkB;QAC3B,MAAM,cAAc,GAA0C,IAAI,CAAC,wBAAwB,EAAE,CAAC;QAC9F,OAAO,cAAc,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,gBAAgB,EAAE,cAAc,CAAC,QAAQ,CAAC,CAAC;IACvG,CAAC;IA4DD,YAAoB,EAClB,aAAa,EACb,WAAW,EACX,aAAa,EACb,sBAAsB,EACtB,eAAe,EACf,gBA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,CAAC,CAAC;IACxE,CAAC;IAED;;;OAGG;IACK,MAAM,CAAC,sBAAsB,CAAC,KAAa,EAAE,SAAiB;QACpE,IAAI,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,GAAG,CAAC,IAAI,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC;YACrD,OAAO;QACT,CAAC;QAED,wCAAwC;QACxC,MAAM,WAAW,GAAW,cAAc,CAAC;QAC3C,MAAM,KAAK,GAA2B,WAAW,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;QAC9D,IAAI,KAAK,EAAE,CAAC;YACV,MAAM,IAAI,KAAK,CAAC,QAAQ,SAAS,2CAA2C,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;QAC3F,CAAC;QACD,MAAM,IAAI,KAAK,CAAC,QAAQ,SAAS,yDAAyD,KAAK,EAAE,CAAC,CAAC;IACrG,CAAC;;AAjlCH,0CAklCC;AAjlCC;;GAEG;AACoB,0BAAU,GAAe,8BAAU,CAAC,gBAAgB,CAAC,mCAAkB,CAAC,CAAC;AAEhG;;GAEG;AACoB,wBAAQ,GAAyB,oBAAoB,CAAC;AAE7E;;;;GAIG;AACoB,kCAAkB,GAAW,IAAI,CAAC,OAAO,CAC9D,SAAS,EACT,+BAA+B,CAChC,CAAC;AAEsB,8BAAc,GAAyB,4BAAQ,CAAC,IAAI,CAC1E,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,wCAAwC,CAAC,CAC/D,CAAC;AAEF,iFAAiF;AACzD,+CAA+B,GAAW,iBAAiB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.\n// See LICENSE in the project root for license information.\n\nimport * as path from 'path';\nimport * as resolve from 'resolve';\nimport lodash = require('lodash');\nimport {\n JsonFile,\n JsonSchema,\n FileSystem,\n PackageJsonLookup,\n type INodePackageJson,\n PackageName,\n Text,\n InternalError,\n Path,\n NewlineKind\n} from '@rushstack/node-core-library';\nimport { type IRigConfig, RigConfig } from '@rushstack/rig-package';\nimport { EnumMemberOrder, ReleaseTag } from '@microsoft/api-extractor-model';\nimport { TSDocConfiguration } from '@microsoft/tsdoc';\nimport { TSDocConfigFile } from '@microsoft/tsdoc-config';\n\nimport type {\n ApiReportVariant,\n IConfigApiReport,\n IConfigFile,\n IExtractorMessagesConfig\n} from './IConfigFile';\nimport { PackageMetadataManager } from '../analyzer/PackageMetadataManager';\nimport { MessageRouter } from '../collector/MessageRouter';\nimport type { IApiModelGenerationOptions } from '../generators/ApiModelGenerator';\n\nimport apiExtractorSchema from '../schemas/api-extractor.schema.json';\n\n/**\n * Tokens used during variable expansion of path fields from api-extractor.json.\n */\ninterface IExtractorConfigTokenContext {\n /**\n * The `<unscopedPackageName>` token returns the project's NPM package name, without any NPM scope.\n * If there is no associated package.json file, then the value is `unknown-package`.\n *\n * Example: `my-project`\n */\n unscopedPackageName: string;\n\n /**\n * The `<packageName>` token returns the project's full NPM package name including any NPM scope.\n * If there is no associated package.json file, then the value is `unknown-package`.\n *\n * Example: `@scope/my-project`\n */\n packageName: string;\n\n /**\n * The `<projectFolder>` token returns the expanded `\"projectFolder\"` setting from api-extractor.json.\n */\n projectFolder: string;\n}\n\n/**\n * Options for {@link ExtractorConfig.tryLoadForFolder}.\n *\n * @public\n */\nexport interface IExtractorConfigLoadForFolderOptions {\n /**\n * The folder path to start from when searching for api-extractor.json.\n */\n startingFolder: string;\n\n /**\n * An already constructed `PackageJsonLookup` cache object to use. If omitted, a temporary one will\n * be constructed.\n */\n packageJsonLookup?: PackageJsonLookup;\n\n /**\n * An already constructed `RigConfig` object. If omitted, then a new `RigConfig` object will be constructed.\n */\n rigConfig?: IRigConfig;\n}\n\n/**\n * Options for {@link ExtractorConfig.prepare}.\n *\n * @public\n */\nexport interface IExtractorConfigPrepareOptions {\n /**\n * A configuration object as returned by {@link ExtractorConfig.loadFile}.\n */\n configObject: IConfigFile;\n\n /**\n * The absolute path of the file that the `configObject` object was loaded from. This is used for error messages\n * and when probing for `tsconfig.json`.\n *\n * @remarks\n *\n * If `configObjectFullPath` and `projectFolderLookupToken` are both unspecified, then the api-extractor.json\n * config file must explicitly specify a `projectFolder` setting rather than relying on the `<lookup>` token.\n */\n configObjectFullPath: string | undefined;\n\n /**\n * The parsed package.json file for the working package, or undefined if API Extractor was invoked without\n * a package.json file.\n *\n * @remarks\n *\n * If omitted, then the `<unscopedPackageName>` and `<packageName>` tokens will have default values.\n */\n packageJson?: INodePackageJson | undefined;\n\n /**\n * The absolute path of the file that the `packageJson` object was loaded from, or undefined if API Extractor\n * was invoked without a package.json file.\n *\n * @remarks\n *\n * This is used for error messages and when resolving paths found in package.json.\n *\n * If `packageJsonFullPath` is specified but `packageJson` is omitted, the file will be loaded automatically.\n */\n packageJsonFullPath: string | undefined;\n\n /**\n * The default value for the `projectFolder` setting is the `<lookup>` token, which uses a heuristic to guess\n * an appropriate project folder. Use `projectFolderLookupValue` to manually specify the `<lookup>` token value\n * instead.\n *\n * @remarks\n * If the `projectFolder` setting is explicitly specified in api-extractor.json file, it should take precedence\n * over a value specified via the API. Thus the `projectFolderLookupToken` option provides a way to override\n * the default value for `projectFolder` setting while still honoring a manually specified value.\n */\n projectFolderLookupToken?: string;\n\n /**\n * Allow customization of the tsdoc.json config file. If omitted, this file will be loaded from its default\n * location. If the file does not exist, then the standard definitions will be used from\n * `@microsoft/api-extractor/extends/tsdoc-base.json`.\n */\n tsdocConfigFile?: TSDocConfigFile;\n\n /**\n * When preparing the configuration object, folder and file paths referenced in the configuration are checked\n * for existence, and an error is reported if they are not found. This option can be used to disable this\n * check for the main entry point module. This may be useful when preparing a configuration file for an\n * un-built project.\n */\n ignoreMissingEntryPoint?: boolean;\n}\n\n/**\n * Configuration for a single API report, including its {@link IExtractorConfigApiReport.variant}.\n *\n * @public\n */\nexport interface IExtractorConfigApiReport {\n /**\n * Report variant.\n * Determines which API items will be included in the report output, based on their tagged release levels.\n */\n variant: ApiReportVariant;\n\n /**\n * Name of the output report file.\n * @remarks Relative to the configured report directory path.\n */\n fileName: string;\n}\n\ninterface IExtractorConfigParameters {\n projectFolder: string;\n packageJson: INodePackageJson | undefined;\n packageFolder: string | undefined;\n mainEntryPointFilePath: string;\n bundledPackages: string[];\n tsconfigFilePath: string;\n overrideTsconfig: {} | undefined;\n skipLibCheck: boolean;\n apiReportEnabled: boolean;\n reportConfigs: readonly IExtractorConfigApiReport[];\n reportFolder: string;\n reportTempFolder: string;\n apiReportIncludeForgottenExports: boolean;\n docModelGenerationOptions: IApiModelGenerationOptions | undefined;\n apiJsonFilePath: string;\n docModelIncludeForgottenExports: boolean;\n projectFolderUrl: string | undefined;\n rollupEnabled: boolean;\n untrimmedFilePath: string;\n alphaTrimmedFilePath: string;\n betaTrimmedFilePath: string;\n publicTrimmedFilePath: string;\n omitTrimmingComments: boolean;\n tsdocMetadataEnabled: boolean;\n tsdocMetadataFilePath: string;\n tsdocConfigFile: TSDocConfigFile;\n tsdocConfiguration: TSDocConfiguration;\n newlineKind: NewlineKind;\n messages: IExtractorMessagesConfig;\n testMode: boolean;\n enumMemberOrder: EnumMemberOrder;\n}\n\n/**\n * The `ExtractorConfig` class loads, validates, interprets, and represents the api-extractor.json config file.\n * @sealed\n * @public\n */\nexport class ExtractorConfig {\n /**\n * The JSON Schema for API Extractor config file (api-extractor.schema.json).\n */\n public static readonly jsonSchema: JsonSchema = JsonSchema.fromLoadedObject(apiExtractorSchema);\n\n /**\n * The config file name \"api-extractor.json\".\n */\n public static readonly FILENAME: 'api-extractor.json' = 'api-extractor.json';\n\n /**\n * The full path to `extends/tsdoc-base.json` which contains the standard TSDoc configuration\n * for API Extractor.\n * @internal\n */\n public static readonly _tsdocBaseFilePath: string = path.resolve(\n __dirname,\n '../../extends/tsdoc-base.json'\n );\n\n private static readonly _defaultConfig: Partial<IConfigFile> = JsonFile.load(\n path.join(__dirname, '../schemas/api-extractor-defaults.json')\n );\n\n /** Match all three flavors for type declaration files (.d.ts, .d.mts, .d.cts) */\n private static readonly _declarationFileExtensionRegExp: RegExp = /\\.d\\.(c|m)?ts$/i;\n\n /** {@inheritDoc IConfigFile.projectFolder} */\n public readonly projectFolder: string;\n\n /**\n * The parsed package.json file for the working package, or undefined if API Extractor was invoked without\n * a package.json file.\n */\n public readonly packageJson: INodePackageJson | undefined;\n\n /**\n * The absolute path of the folder containing the package.json file for the working package, or undefined\n * if API Extractor was invoked without a package.json file.\n */\n public readonly packageFolder: string | undefined;\n\n /** {@inheritDoc IConfigFile.mainEntryPointFilePath} */\n public readonly mainEntryPointFilePath: string;\n\n /** {@inheritDoc IConfigFile.bundledPackages} */\n public readonly bundledPackages: string[];\n\n /** {@inheritDoc IConfigCompiler.tsconfigFilePath} */\n public readonly tsconfigFilePath: string;\n\n /** {@inheritDoc IConfigCompiler.overrideTsconfig} */\n public readonly overrideTsconfig: {} | undefined;\n\n /** {@inheritDoc IConfigCompiler.skipLibCheck} */\n public readonly skipLibCheck: boolean;\n\n /** {@inheritDoc IConfigApiReport.enabled} */\n public readonly apiReportEnabled: boolean;\n\n /**\n * List of configurations for report files to be generated.\n * @remarks Derived from {@link IConfigApiReport.reportFileName} and {@link IConfigApiReport.reportVariants}.\n */\n public readonly reportConfigs: readonly IExtractorConfigApiReport[];\n /** {@inheritDoc IConfigApiReport.reportFolder} */\n public readonly reportFolder: string;\n /** {@inheritDoc IConfigApiReport.reportTempFolder} */\n public readonly reportTempFolder: string;\n\n /**\n * Gets the file path for the \"complete\" (default) report configuration, if one was specified.\n * Otherwise, returns an empty string.\n * @deprecated Use {@link ExtractorConfig.reportConfigs} to access all report configurations.\n */\n public get reportFilePath(): string {\n const completeConfig: IExtractorConfigApiReport | undefined = this._getCompleteReportConfig();\n return completeConfig === undefined ? '' : path.join(this.reportFolder, completeConfig.fileName);\n }\n\n /**\n * Gets the temp file path for the \"complete\" (default) report configuration, if one was specified.\n * Otherwise, returns an empty string.\n * @deprecated Use {@link ExtractorConfig.reportConfigs} to access all report configurations.\n */\n public get reportTempFilePath(): string {\n const completeConfig: IExtractorConfigApiReport | undefined = this._getCompleteReportConfig();\n return completeConfig === undefined ? '' : path.join(this.reportTempFolder, completeConfig.fileName);\n }\n\n /** {@inheritDoc IConfigApiReport.includeForgottenExports} */\n public readonly apiReportIncludeForgottenExports: boolean;\n\n /**\n * If specified, the doc model is enabled and the specified options will be used.\n * @beta\n */\n public readonly docModelGenerationOptions: IApiModelGenerationOptions | undefined;\n /** {@inheritDoc IConfigDocModel.apiJsonFilePath} */\n public readonly apiJsonFilePath: string;\n /** {@inheritDoc IConfigDocModel.includeForgottenExports} */\n public readonly docModelIncludeForgottenExports: boolean;\n /** {@inheritDoc IConfigDocModel.projectFolderUrl} */\n public readonly projectFolderUrl: string | undefined;\n\n /** {@inheritDoc IConfigDtsRollup.enabled} */\n public readonly rollupEnabled: boolean;\n /** {@inheritDoc IConfigDtsRollup.untrimmedFilePath} */\n public readonly untrimmedFilePath: string;\n /** {@inheritDoc IConfigDtsRollup.alphaTrimmedFilePath} */\n public readonly alphaTrimmedFilePath: string;\n /** {@inheritDoc IConfigDtsRollup.betaTrimmedFilePath} */\n public readonly betaTrimmedFilePath: string;\n /** {@inheritDoc IConfigDtsRollup.publicTrimmedFilePath} */\n public readonly publicTrimmedFilePath: string;\n /** {@inheritDoc IConfigDtsRollup.omitTrimmingComments} */\n public readonly omitTrimmingComments: boolean;\n\n /** {@inheritDoc IConfigTsdocMetadata.enabled} */\n public readonly tsdocMetadataEnabled: boolean;\n /** {@inheritDoc IConfigTsdocMetadata.tsdocMetadataFilePath} */\n public readonly tsdocMetadataFilePath: string;\n\n /**\n * The tsdoc.json configuration that will be used when parsing doc comments.\n */\n public readonly tsdocConfigFile: TSDocConfigFile;\n\n /**\n * The `TSDocConfiguration` loaded from {@link ExtractorConfig.tsdocConfigFile}.\n */\n public readonly tsdocConfiguration: TSDocConfiguration;\n\n /**\n * Specifies what type of newlines API Extractor should use when writing output files. By default, the output files\n * will be written with Windows-style newlines.\n */\n public readonly newlineKind: NewlineKind;\n\n /** {@inheritDoc IConfigFile.messages} */\n public readonly messages: IExtractorMessagesConfig;\n\n /** {@inheritDoc IConfigFile.testMode} */\n public readonly testMode: boolean;\n\n /** {@inheritDoc IConfigFile.enumMemberOrder} */\n public readonly enumMemberOrder: EnumMemberOrder;\n\n private constructor({\n projectFolder,\n packageJson,\n packageFolder,\n mainEntryPointFilePath,\n bundledPackages,\n tsconfigFilePath,\n overrideTsconfig,\n skipLibCheck,\n apiReportEnabled,\n apiReportIncludeForgottenExports,\n reportConfigs,\n reportFolder,\n reportTempFolder,\n docModelGenerationOptions,\n apiJsonFilePath,\n docModelIncludeForgottenExports,\n projectFolderUrl,\n rollupEnabled,\n untrimmedFilePath,\n alphaTrimmedFilePath,\n betaTrimmedFilePath,\n publicTrimmedFilePath,\n omitTrimmingComments,\n tsdocMetadataEnabled,\n tsdocMetadataFilePath,\n tsdocConfigFile,\n tsdocConfiguration,\n newlineKind,\n messages,\n testMode,\n enumMemberOrder\n }: IExtractorConfigParameters) {\n this.projectFolder = projectFolder;\n this.packageJson = packageJson;\n this.packageFolder = packageFolder;\n this.mainEntryPointFilePath = mainEntryPointFilePath;\n this.bundledPackages = bundledPackages;\n this.tsconfigFilePath = tsconfigFilePath;\n this.overrideTsconfig = overrideTsconfig;\n this.skipLibCheck = skipLibCheck;\n this.apiReportEnabled = apiReportEnabled;\n this.apiReportIncludeForgottenExports = apiReportIncludeForgottenExports;\n this.reportConfigs = reportConfigs;\n this.reportFolder = reportFolder;\n this.reportTempFolder = reportTempFolder;\n this.docModelGenerationOptions = docModelGenerationOptions;\n this.apiJsonFilePath = apiJsonFilePath;\n this.docModelIncludeForgottenExports = docModelIncludeForgottenExports;\n this.projectFolderUrl = projectFolderUrl;\n this.rollupEnabled = rollupEnabled;\n this.untrimmedFilePath = untrimmedFilePath;\n this.alphaTrimmedFilePath = alphaTrimmedFilePath;\n this.betaTrimmedFilePath = betaTrimmedFilePath;\n this.publicTrimmedFilePath = publicTrimmedFilePath;\n this.omitTrimmingComments = omitTrimmingComments;\n this.tsdocMetadataEnabled = tsdocMetadataEnabled;\n this.tsdocMetadataFilePath = tsdocMetadataFilePath;\n this.tsdocConfigFile = tsdocConfigFile;\n this.tsdocConfiguration = tsdocConfiguration;\n this.newlineKind = newlineKind;\n this.messages = messages;\n this.testMode = testMode;\n this.enumMemberOrder = enumMemberOrder;\n }\n\n /**\n * Returns a JSON-like string representing the `ExtractorConfig` state, which can be printed to a console\n * for diagnostic purposes.\n *\n * @remarks\n * This is used by the \"--diagnostics\" command-line option. The string is not intended to be deserialized;\n * its format may be changed at any time.\n */\n public getDiagnosticDump(): string {\n // Handle the simple JSON-serializable properties using buildJsonDumpObject()\n const result: object = MessageRouter.buildJsonDumpObject(this, {\n keyNamesToOmit: ['tsdocConfigFile', 'tsdocConfiguration']\n });\n\n // Implement custom formatting for tsdocConfigFile and tsdocConfiguration\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n (result as any).tsdocConfigFile = {\n filePath: this.tsdocConfigFile.filePath,\n log: this.tsdocConfigFile.log.messages.map((x) => x.toString())\n };\n\n return JSON.stringify(result, undefined, 2);\n }\n\n /**\n * Returns a simplified file path for use in error messages.\n * @internal\n */\n public _getShortFilePath(absolutePath: string): string {\n if (!path.isAbsolute(absolutePath)) {\n throw new InternalError('Expected absolute path: ' + absolutePath);\n }\n if (Path.isUnderOrEqual(absolutePath, this.projectFolder)) {\n return Path.convertToSlashes(path.relative(this.projectFolder, absolutePath));\n }\n return absolutePath;\n }\n\n /**\n * Searches for the api-extractor.json config file associated with the specified starting folder,\n * and loads the file if found. This lookup supports\n * {@link https://www.npmjs.com/package/@rushstack/rig-package | rig packages}.\n *\n * @remarks\n * The search will first look for a package.json file in a parent folder of the starting folder;\n * if found, that will be used as the base folder instead of the starting folder. If the config\n * file is not found in `<baseFolder>/api-extractor.json` or `<baseFolder>/config/api-extractor.json`,\n * then `<baseFolder/config/rig.json` will be checked to see whether a\n * {@link https://www.npmjs.com/package/@rushstack/rig-package | rig package} is referenced; if so then\n * the rig's api-extractor.json file will be used instead. If a config file is found, it will be loaded\n * and returned with the `IExtractorConfigPrepareOptions` object. Otherwise, `undefined` is returned\n * to indicate that API Extractor does not appear to be configured for the specified folder.\n *\n * @returns An options object that can be passed to {@link ExtractorConfig.prepare}, or `undefined`\n * if not api-extractor.json file was found.\n */\n public static tryLoadForFolder(\n options: IExtractorConfigLoadForFolderOptions\n ): IExtractorConfigPrepareOptions | undefined {\n const packageJsonLookup: PackageJsonLookup = options.packageJsonLookup || new PackageJsonLookup();\n const startingFolder: string = options.startingFolder;\n\n // Figure out which project we're in and look for the config file at the project root\n const packageJsonFullPath: string | undefined =\n packageJsonLookup.tryGetPackageJsonFilePathFor(startingFolder);\n const packageFolder: string | undefined = packageJsonFullPath\n ? path.dirname(packageJsonFullPath)\n : undefined;\n\n // If there is no package, then just use the starting folder\n const baseFolder: string = packageFolder || startingFolder;\n\n let projectFolderLookupToken: string | undefined = undefined;\n\n // First try the standard \"config\" subfolder:\n let configFilename: string = path.join(baseFolder, 'config', ExtractorConfig.FILENAME);\n if (FileSystem.exists(configFilename)) {\n if (FileSystem.exists(path.join(baseFolder, ExtractorConfig.FILENAME))) {\n throw new Error(`Found conflicting ${ExtractorConfig.FILENAME} files in \".\" and \"./config\" folders`);\n }\n } else {\n // Otherwise try the top-level folder\n configFilename = path.join(baseFolder, ExtractorConfig.FILENAME);\n\n if (!FileSystem.exists(configFilename)) {\n // If We didn't find it in <packageFolder>/api-extractor.json or <packageFolder>/config/api-extractor.json\n // then check for a rig package\n if (packageFolder) {\n let rigConfig: IRigConfig;\n if (options.rigConfig) {\n // The caller provided an already solved RigConfig. Double-check that it is for the right project.\n if (!Path.isEqual(options.rigConfig.projectFolderPath, packageFolder)) {\n throw new Error(\n 'The provided ILoadForFolderOptions.rigConfig is for the wrong project folder:\\n' +\n '\\nExpected path: ' +\n packageFolder +\n '\\nProvided path: ' +\n options.rigConfig.projectFolderOriginalPath\n );\n }\n rigConfig = options.rigConfig;\n } else {\n rigConfig = RigConfig.loadForProjectFolder({\n projectFolderPath: packageFolder\n });\n }\n\n if (rigConfig.rigFound) {\n configFilename = path.join(rigConfig.getResolvedProfileFolder(), ExtractorConfig.FILENAME);\n\n // If the \"projectFolder\" setting isn't specified in api-extractor.json, it defaults to the\n // \"<lookup>\" token which will probe for the tsconfig.json nearest to the api-extractor.json path.\n // But this won't work if api-extractor.json belongs to the rig. So instead \"<lookup>\" should be\n // the \"<packageFolder>\" that referenced the rig.\n projectFolderLookupToken = packageFolder;\n }\n }\n if (!FileSystem.exists(configFilename)) {\n // API Extractor does not seem to be configured for this folder\n return undefined;\n }\n }\n }\n\n const configObjectFullPath: string = path.resolve(configFilename);\n const configObject: IConfigFile = ExtractorConfig.loadFile(configObjectFullPath);\n\n return {\n configObject,\n configObjectFullPath,\n packageJsonFullPath,\n projectFolderLookupToken\n };\n }\n\n /**\n * Loads the api-extractor.json config file from the specified file path, and prepares an `ExtractorConfig` object.\n *\n * @remarks\n * Loads the api-extractor.json config file from the specified file path. If the \"extends\" field is present,\n * the referenced file(s) will be merged. For any omitted fields, the API Extractor default values are merged.\n *\n * The result is prepared using `ExtractorConfig.prepare()`.\n */\n public static loadFileAndPrepare(configJsonFilePath: string): ExtractorConfig {\n const configObjectFullPath: string = path.resolve(configJsonFilePath);\n const configObject: IConfigFile = ExtractorConfig.loadFile(configObjectFullPath);\n\n const packageJsonLookup: PackageJsonLookup = new PackageJsonLookup();\n const packageJsonFullPath: string | undefined =\n packageJsonLookup.tryGetPackageJsonFilePathFor(configObjectFullPath);\n\n const extractorConfig: ExtractorConfig = ExtractorConfig.prepare({\n configObject,\n configObjectFullPath,\n packageJsonFullPath\n });\n\n return extractorConfig;\n }\n\n /**\n * Performs only the first half of {@link ExtractorConfig.loadFileAndPrepare}, providing an opportunity to\n * modify the object before it is passed to {@link ExtractorConfig.prepare}.\n *\n * @remarks\n * Loads the api-extractor.json config file from the specified file path. If the \"extends\" field is present,\n * the referenced file(s) will be merged. For any omitted fields, the API Extractor default values are merged.\n */\n public static loadFile(jsonFilePath: string): IConfigFile {\n // Set to keep track of config files which have been processed.\n const visitedPaths: Set<string> = new Set<string>();\n\n let currentConfigFilePath: string = path.resolve(jsonFilePath);\n let configObject: Partial<IConfigFile> = {};\n\n // Lodash merges array values by default, which is unintuitive for config files (and makes it impossible for derived configurations to overwrite arrays).\n // For example, given a base config containing an array property with value [\"foo\", \"bar\"] and a derived config that specifies [\"baz\"] for that property, lodash will produce [\"baz\", \"bar\"], which is unintuitive.\n // This customizer function ensures that arrays are always overwritten.\n const mergeCustomizer: lodash.MergeWithCustomizer = (objValue, srcValue) => {\n if (Array.isArray(srcValue)) {\n return srcValue;\n }\n // Fall back to default merge behavior.\n return undefined;\n };\n\n try {\n do {\n // Check if this file was already processed.\n if (visitedPaths.has(currentConfigFilePath)) {\n throw new Error(\n `The API Extractor \"extends\" setting contains a cycle.` +\n ` This file is included twice: \"${currentConfigFilePath}\"`\n );\n }\n visitedPaths.add(currentConfigFilePath);\n\n const currentConfigFolderPath: string = path.dirname(currentConfigFilePath);\n\n // Load the extractor config defined in extends property.\n const baseConfig: IConfigFile = JsonFile.load(currentConfigFilePath);\n\n let extendsField: string = baseConfig.extends || '';\n\n // Delete the \"extends\" field so it doesn't get merged\n delete baseConfig.extends;\n\n if (extendsField) {\n if (extendsField.match(/^\\.\\.?[\\\\/]/)) {\n // EXAMPLE: \"./subfolder/api-extractor-base.json\"\n extendsField = path.resolve(currentConfigFolderPath, extendsField);\n } else {\n // EXAMPLE: \"my-package/api-extractor-base.json\"\n //\n // Resolve \"my-package\" from the perspective of the current folder.\n try {\n extendsField = resolve.sync(extendsField, {\n basedir: currentConfigFolderPath\n });\n } catch (e) {\n throw new Error(`Error resolving NodeJS path \"${extendsField}\": ${(e as Error).message}`);\n }\n }\n }\n\n // This step has to be performed in advance, since the currentConfigFolderPath information will be lost\n // after lodash.merge() is performed.\n ExtractorConfig._resolveConfigFileRelativePaths(baseConfig, currentConfigFolderPath);\n\n // Merge extractorConfig into baseConfig, mutating baseConfig\n lodash.mergeWith(baseConfig, configObject, mergeCustomizer);\n configObject = baseConfig;\n\n currentConfigFilePath = extendsField;\n } while (currentConfigFilePath);\n } catch (e) {\n throw new Error(`Error loading ${currentConfigFilePath}:\\n` + (e as Error).message);\n }\n\n // Lastly, apply the defaults\n configObject = lodash.mergeWith(\n lodash.cloneDeep(ExtractorConfig._defaultConfig),\n configObject,\n mergeCustomizer\n );\n\n ExtractorConfig.jsonSchema.validateObject(configObject, jsonFilePath);\n\n // The schema validation should ensure that this object conforms to IConfigFile\n return configObject as IConfigFile;\n }\n\n private static _resolveConfigFileRelativePaths(\n configFile: IConfigFile,\n currentConfigFolderPath: string\n ): void {\n if (configFile.projectFolder) {\n configFile.projectFolder = ExtractorConfig._resolveConfigFileRelativePath(\n 'projectFolder',\n configFile.projectFolder,\n currentConfigFolderPath\n );\n }\n\n if (configFile.mainEntryPointFilePath) {\n configFile.mainEntryPointFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'mainEntryPointFilePath',\n configFile.mainEntryPointFilePath,\n currentConfigFolderPath\n );\n }\n\n if (configFile.compiler) {\n if (configFile.compiler.tsconfigFilePath) {\n configFile.compiler.tsconfigFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'tsconfigFilePath',\n configFile.compiler.tsconfigFilePath,\n currentConfigFolderPath\n );\n }\n }\n\n if (configFile.apiReport) {\n if (configFile.apiReport.reportFolder) {\n configFile.apiReport.reportFolder = ExtractorConfig._resolveConfigFileRelativePath(\n 'reportFolder',\n configFile.apiReport.reportFolder,\n currentConfigFolderPath\n );\n }\n if (configFile.apiReport.reportTempFolder) {\n configFile.apiReport.reportTempFolder = ExtractorConfig._resolveConfigFileRelativePath(\n 'reportTempFolder',\n configFile.apiReport.reportTempFolder,\n currentConfigFolderPath\n );\n }\n }\n\n if (configFile.docModel) {\n if (configFile.docModel.apiJsonFilePath) {\n configFile.docModel.apiJsonFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'apiJsonFilePath',\n configFile.docModel.apiJsonFilePath,\n currentConfigFolderPath\n );\n }\n }\n\n if (configFile.dtsRollup) {\n if (configFile.dtsRollup.untrimmedFilePath) {\n configFile.dtsRollup.untrimmedFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'untrimmedFilePath',\n configFile.dtsRollup.untrimmedFilePath,\n currentConfigFolderPath\n );\n }\n if (configFile.dtsRollup.alphaTrimmedFilePath) {\n configFile.dtsRollup.alphaTrimmedFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'alphaTrimmedFilePath',\n configFile.dtsRollup.alphaTrimmedFilePath,\n currentConfigFolderPath\n );\n }\n if (configFile.dtsRollup.betaTrimmedFilePath) {\n configFile.dtsRollup.betaTrimmedFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'betaTrimmedFilePath',\n configFile.dtsRollup.betaTrimmedFilePath,\n currentConfigFolderPath\n );\n }\n if (configFile.dtsRollup.publicTrimmedFilePath) {\n configFile.dtsRollup.publicTrimmedFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'publicTrimmedFilePath',\n configFile.dtsRollup.publicTrimmedFilePath,\n currentConfigFolderPath\n );\n }\n }\n\n if (configFile.tsdocMetadata) {\n if (configFile.tsdocMetadata.tsdocMetadataFilePath) {\n configFile.tsdocMetadata.tsdocMetadataFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'tsdocMetadataFilePath',\n configFile.tsdocMetadata.tsdocMetadataFilePath,\n currentConfigFolderPath\n );\n }\n }\n }\n\n private static _resolveConfigFileRelativePath(\n fieldName: string,\n fieldValue: string,\n currentConfigFolderPath: string\n ): string {\n if (!path.isAbsolute(fieldValue)) {\n if (fieldValue.indexOf('<projectFolder>') !== 0) {\n // If the path is not absolute and does not start with \"<projectFolder>\", then resolve it relative\n // to the folder of the config file that it appears in\n return path.join(currentConfigFolderPath, fieldValue);\n }\n }\n\n return fieldValue;\n }\n\n /**\n * Prepares an `ExtractorConfig` object using a configuration that is provided as a runtime object,\n * rather than reading it from disk. This allows configurations to be constructed programmatically,\n * loaded from an alternate source, and/or customized after loading.\n */\n public static prepare(options: IExtractorConfigPrepareOptions): ExtractorConfig {\n const filenameForErrors: string = options.configObjectFullPath || 'the configuration object';\n const configObject: Partial<IConfigFile> = options.configObject;\n\n if (configObject.extends) {\n throw new Error(\n 'The IConfigFile.extends field must be expanded before calling ExtractorConfig.prepare()'\n );\n }\n\n if (options.configObjectFullPath) {\n if (!path.isAbsolute(options.configObjectFullPath)) {\n throw new Error('The \"configObjectFullPath\" setting must be an absolute path');\n }\n }\n\n ExtractorConfig.jsonSchema.validateObject(configObject, filenameForErrors);\n\n const packageJsonFullPath: string | undefined = options.packageJsonFullPath;\n let packageFolder: string | undefined = undefined;\n let packageJson: INodePackageJson | undefined = undefined;\n\n if (packageJsonFullPath) {\n if (!/.json$/i.test(packageJsonFullPath)) {\n // Catch common mistakes e.g. where someone passes a folder path instead of a file path\n throw new Error('The \"packageJsonFullPath\" setting does not have a .json file extension');\n }\n if (!path.isAbsolute(packageJsonFullPath)) {\n throw new Error('The \"packageJsonFullPath\" setting must be an absolute path');\n }\n\n if (options.packageJson) {\n packageJson = options.packageJson;\n } else {\n const packageJsonLookup: PackageJsonLookup = new PackageJsonLookup();\n packageJson = packageJsonLookup.loadNodePackageJson(packageJsonFullPath);\n }\n\n packageFolder = path.dirname(packageJsonFullPath);\n }\n\n // \"tsdocConfigFile\" and \"tsdocConfiguration\" are prepared outside the try-catch block,\n // so that if exceptions are thrown, it will not get the \"Error parsing api-extractor.json:\" header\n let extractorConfigParameters: Omit<IExtractorConfigParameters, 'tsdocConfigFile' | 'tsdocConfiguration'>;\n\n try {\n if (!configObject.compiler) {\n // A merged configuration should have this\n throw new Error('The \"compiler\" section is missing');\n }\n\n if (!configObject.projectFolder) {\n // A merged configuration should have this\n throw new Error('The \"projectFolder\" setting is missing');\n }\n\n let projectFolder: string;\n if (configObject.projectFolder.trim() === '<lookup>') {\n if (options.projectFolderLookupToken) {\n // Use the manually specified \"<lookup>\" value\n projectFolder = options.projectFolderLookupToken;\n\n if (!FileSystem.exists(options.projectFolderLookupToken)) {\n throw new Error(\n 'The specified \"projectFolderLookupToken\" path does not exist: ' +\n options.projectFolderLookupToken\n );\n }\n } else {\n if (!options.configObjectFullPath) {\n throw new Error(\n 'The \"projectFolder\" setting uses the \"<lookup>\" token, but it cannot be expanded because' +\n ' the \"configObjectFullPath\" setting was not specified'\n );\n }\n\n // \"The default value for `projectFolder` is the token `<lookup>`, which means the folder is determined\n // by traversing parent folders, starting from the folder containing api-extractor.json, and stopping\n // at the first folder that contains a tsconfig.json file. If a tsconfig.json file cannot be found in\n // this way, then an error will be reported.\"\n\n let currentFolder: string = path.dirname(options.configObjectFullPath);\n for (;;) {\n const tsconfigPath: string = path.join(currentFolder, 'tsconfig.json');\n if (FileSystem.exists(tsconfigPath)) {\n projectFolder = currentFolder;\n break;\n }\n const parentFolder: string = path.dirname(currentFolder);\n if (parentFolder === '' || parentFolder === currentFolder) {\n throw new Error(\n 'The \"projectFolder\" setting uses the \"<lookup>\" token, but a tsconfig.json file cannot be' +\n ' found in this folder or any parent folder.'\n );\n }\n currentFolder = parentFolder;\n }\n }\n } else {\n ExtractorConfig._rejectAnyTokensInPath(configObject.projectFolder, 'projectFolder');\n\n if (!FileSystem.exists(configObject.projectFolder)) {\n throw new Error('The specified \"projectFolder\" path does not exist: ' + configObject.projectFolder);\n }\n\n projectFolder = configObject.projectFolder;\n }\n\n const tokenContext: IExtractorConfigTokenContext = {\n unscopedPackageName: 'unknown-package',\n packageName: 'unknown-package',\n projectFolder: projectFolder\n };\n\n if (packageJson) {\n tokenContext.packageName = packageJson.name;\n tokenContext.unscopedPackageName = PackageName.getUnscopedName(packageJson.name);\n }\n\n if (!configObject.mainEntryPointFilePath) {\n // A merged configuration should have this\n throw new Error('The \"mainEntryPointFilePath\" setting is missing');\n }\n const mainEntryPointFilePath: string = ExtractorConfig._resolvePathWithTokens(\n 'mainEntryPointFilePath',\n configObject.mainEntryPointFilePath,\n tokenContext\n );\n\n if (!ExtractorConfig.hasDtsFileExtension(mainEntryPointFilePath)) {\n throw new Error(\n 'The \"mainEntryPointFilePath\" value is not a declaration file: ' + mainEntryPointFilePath\n );\n }\n\n if (!options.ignoreMissingEntryPoint && !FileSystem.exists(mainEntryPointFilePath)) {\n throw new Error('The \"mainEntryPointFilePath\" path does not exist: ' + mainEntryPointFilePath);\n }\n\n const bundledPackages: string[] = configObject.bundledPackages || [];\n\n // Note: we cannot fully validate package name patterns, as the strings may contain wildcards.\n // We won't know if the entries are valid until we can compare them against the package.json \"dependencies\" contents.\n\n const tsconfigFilePath: string = ExtractorConfig._resolvePathWithTokens(\n 'tsconfigFilePath',\n configObject.compiler.tsconfigFilePath,\n tokenContext\n );\n\n if (configObject.compiler.overrideTsconfig === undefined) {\n if (!tsconfigFilePath) {\n throw new Error('Either the \"tsconfigFilePath\" or \"overrideTsconfig\" setting must be specified');\n }\n if (!FileSystem.exists(tsconfigFilePath)) {\n throw new Error('The file referenced by \"tsconfigFilePath\" does not exist: ' + tsconfigFilePath);\n }\n }\n\n const apiReportEnabled: boolean = configObject.apiReport?.enabled ?? false;\n const apiReportIncludeForgottenExports: boolean =\n configObject.apiReport?.includeForgottenExports ?? false;\n let reportFolder: string = tokenContext.projectFolder;\n let reportTempFolder: string = tokenContext.projectFolder;\n const reportConfigs: IExtractorConfigApiReport[] = [];\n if (apiReportEnabled) {\n // Undefined case checked above where we assign `apiReportEnabled`\n const apiReportConfig: IConfigApiReport = configObject.apiReport!;\n\n const reportFileNameSuffix: string = '.api.md';\n let reportFileNameBase: string;\n if (apiReportConfig.reportFileName) {\n if (\n apiReportConfig.reportFileName.indexOf('/') >= 0 ||\n apiReportConfig.reportFileName.indexOf('\\\\') >= 0\n ) {\n throw new Error(\n `The \"reportFileName\" setting contains invalid characters: \"${apiReportConfig.reportFileName}\"`\n );\n }\n\n if (!apiReportConfig.reportFileName.endsWith(reportFileNameSuffix)) {\n // `.api.md` extension was not specified. Use provided file name base as is.\n reportFileNameBase = apiReportConfig.reportFileName;\n } else {\n // The system previously asked users to specify their filenames in a form containing the `.api.md` extension.\n // This guidance has changed, but to maintain backwards compatibility, we will temporarily support input\n // that ends with the `.api.md` extension specially, by stripping it out.\n // This should be removed in version 8, possibly replaced with an explicit error to help users\n // migrate their configs.\n reportFileNameBase = apiReportConfig.reportFileName.slice(0, -reportFileNameSuffix.length);\n }\n } else {\n // Default value\n reportFileNameBase = '<unscopedPackageName>';\n }\n\n const reportVariantKinds: ApiReportVariant[] = apiReportConfig.reportVariants ?? ['complete'];\n\n for (const reportVariantKind of reportVariantKinds) {\n // Omit the variant kind from the \"complete\" report file name for simplicity and for backwards compatibility.\n const fileNameWithTokens: string = `${reportFileNameBase}${\n reportVariantKind === 'complete' ? '' : `.${reportVariantKind}`\n }${reportFileNameSuffix}`;\n const normalizedFileName: string = ExtractorConfig._expandStringWithTokens(\n 'reportFileName',\n fileNameWithTokens,\n tokenContext\n );\n\n reportConfigs.push({\n fileName: normalizedFileName,\n variant: reportVariantKind\n });\n }\n\n if (apiReportConfig.reportFolder) {\n reportFolder = ExtractorConfig._resolvePathWithTokens(\n 'reportFolder',\n apiReportConfig.reportFolder,\n tokenContext\n );\n }\n\n if (apiReportConfig.reportTempFolder) {\n reportTempFolder = ExtractorConfig._resolvePathWithTokens(\n 'reportTempFolder',\n apiReportConfig.reportTempFolder,\n tokenContext\n );\n }\n }\n\n let docModelGenerationOptions: IApiModelGenerationOptions | undefined = undefined;\n let apiJsonFilePath: string = '';\n let docModelIncludeForgottenExports: boolean = false;\n let projectFolderUrl: string | undefined;\n if (configObject.docModel?.enabled) {\n apiJsonFilePath = ExtractorConfig._resolvePathWithTokens(\n 'apiJsonFilePath',\n configObject.docModel.apiJsonFilePath,\n tokenContext\n );\n docModelIncludeForgottenExports = !!configObject.docModel.includeForgottenExports;\n projectFolderUrl = configObject.docModel.projectFolderUrl;\n\n const releaseTagsToTrim: Set<ReleaseTag> = new Set<ReleaseTag>();\n const releaseTagsToTrimOption: string[] = configObject.docModel.releaseTagsToTrim || ['@internal'];\n for (const releaseTagToTrim of releaseTagsToTrimOption) {\n let releaseTag: ReleaseTag;\n switch (releaseTagToTrim) {\n case '@internal': {\n releaseTag = ReleaseTag.Internal;\n break;\n }\n\n case '@alpha': {\n releaseTag = ReleaseTag.Alpha;\n break;\n }\n\n case '@beta': {\n releaseTag = ReleaseTag.Beta;\n break;\n }\n\n case '@public': {\n releaseTag = ReleaseTag.Public;\n break;\n }\n\n default: {\n throw new Error(`The release tag \"${releaseTagToTrim}\" is not supported`);\n }\n }\n\n releaseTagsToTrim.add(releaseTag);\n }\n\n docModelGenerationOptions = {\n releaseTagsToTrim\n };\n }\n\n let tsdocMetadataEnabled: boolean = false;\n let tsdocMetadataFilePath: string = '';\n if (configObject.tsdocMetadata) {\n tsdocMetadataEnabled = !!configObject.tsdocMetadata.enabled;\n\n if (tsdocMetadataEnabled) {\n tsdocMetadataFilePath = configObject.tsdocMetadata.tsdocMetadataFilePath || '';\n\n if (tsdocMetadataFilePath.trim() === '<lookup>') {\n if (!packageJson) {\n throw new Error(\n 'The \"<lookup>\" token cannot be used with the \"tsdocMetadataFilePath\" setting because' +\n ' the \"packageJson\" option was not provided'\n );\n }\n if (!packageJsonFullPath) {\n throw new Error(\n 'The \"<lookup>\" token cannot be used with \"tsdocMetadataFilePath\" because' +\n 'the \"packageJsonFullPath\" option was not provided'\n );\n }\n tsdocMetadataFilePath = PackageMetadataManager.resolveTsdocMetadataPath(\n path.dirname(packageJsonFullPath),\n packageJson\n );\n } else {\n tsdocMetadataFilePath = ExtractorConfig._resolvePathWithTokens(\n 'tsdocMetadataFilePath',\n configObject.tsdocMetadata.tsdocMetadataFilePath,\n tokenContext\n );\n }\n\n if (!tsdocMetadataFilePath) {\n throw new Error(\n 'The \"tsdocMetadata.enabled\" setting is enabled,' +\n ' but \"tsdocMetadataFilePath\" is not specified'\n );\n }\n }\n }\n\n let rollupEnabled: boolean = false;\n let untrimmedFilePath: string = '';\n let betaTrimmedFilePath: string = '';\n let alphaTrimmedFilePath: string = '';\n let publicTrimmedFilePath: string = '';\n let omitTrimmingComments: boolean = false;\n\n if (configObject.dtsRollup) {\n rollupEnabled = !!configObject.dtsRollup.enabled;\n untrimmedFilePath = ExtractorConfig._resolvePathWithTokens(\n 'untrimmedFilePath',\n configObject.dtsRollup.untrimmedFilePath,\n tokenContext\n );\n alphaTrimmedFilePath = ExtractorConfig._resolvePathWithTokens(\n 'alphaTrimmedFilePath',\n configObject.dtsRollup.alphaTrimmedFilePath,\n tokenContext\n );\n betaTrimmedFilePath = ExtractorConfig._resolvePathWithTokens(\n 'betaTrimmedFilePath',\n configObject.dtsRollup.betaTrimmedFilePath,\n tokenContext\n );\n publicTrimmedFilePath = ExtractorConfig._resolvePathWithTokens(\n 'publicTrimmedFilePath',\n configObject.dtsRollup.publicTrimmedFilePath,\n tokenContext\n );\n omitTrimmingComments = !!configObject.dtsRollup.omitTrimmingComments;\n }\n\n let newlineKind: NewlineKind;\n switch (configObject.newlineKind) {\n case 'lf':\n newlineKind = NewlineKind.Lf;\n break;\n case 'os':\n newlineKind = NewlineKind.OsDefault;\n break;\n default:\n newlineKind = NewlineKind.CrLf;\n break;\n }\n\n const enumMemberOrder: EnumMemberOrder = configObject.enumMemberOrder ?? EnumMemberOrder.ByName;\n\n extractorConfigParameters = {\n projectFolder: projectFolder,\n packageJson,\n packageFolder,\n mainEntryPointFilePath,\n bundledPackages,\n tsconfigFilePath,\n overrideTsconfig: configObject.compiler.overrideTsconfig,\n skipLibCheck: !!configObject.compiler.skipLibCheck,\n apiReportEnabled,\n reportConfigs,\n reportFolder,\n reportTempFolder,\n apiReportIncludeForgottenExports,\n docModelGenerationOptions,\n apiJsonFilePath,\n docModelIncludeForgottenExports,\n projectFolderUrl,\n rollupEnabled,\n untrimmedFilePath,\n alphaTrimmedFilePath,\n betaTrimmedFilePath,\n publicTrimmedFilePath,\n omitTrimmingComments,\n tsdocMetadataEnabled,\n tsdocMetadataFilePath,\n newlineKind,\n messages: configObject.messages || {},\n testMode: !!configObject.testMode,\n enumMemberOrder\n };\n } catch (e) {\n throw new Error(`Error parsing ${filenameForErrors}:\\n` + (e as Error).message);\n }\n\n let tsdocConfigFile: TSDocConfigFile | undefined = options.tsdocConfigFile;\n\n if (!tsdocConfigFile) {\n // Example: \"my-project/tsdoc.json\"\n let packageTSDocConfigPath: string = TSDocConfigFile.findConfigPathForFolder(\n extractorConfigParameters.projectFolder\n );\n\n if (!packageTSDocConfigPath || !FileSystem.exists(packageTSDocConfigPath)) {\n // If the project does not have a tsdoc.json config file, then use API Extractor's base file.\n packageTSDocConfigPath = ExtractorConfig._tsdocBaseFilePath;\n if (!FileSystem.exists(packageTSDocConfigPath)) {\n throw new InternalError('Unable to load the built-in TSDoc config file: ' + packageTSDocConfigPath);\n }\n }\n tsdocConfigFile = TSDocConfigFile.loadFile(packageTSDocConfigPath);\n }\n\n // IMPORTANT: After calling TSDocConfigFile.loadFile(), we need to check for errors.\n if (tsdocConfigFile.hasErrors) {\n throw new Error(tsdocConfigFile.getErrorSummary());\n }\n\n const tsdocConfiguration: TSDocConfiguration = new TSDocConfiguration();\n tsdocConfigFile.configureParser(tsdocConfiguration);\n\n // IMPORTANT: After calling TSDocConfigFile.configureParser(), we need to check for errors a second time.\n if (tsdocConfigFile.hasErrors) {\n throw new Error(tsdocConfigFile.getErrorSummary());\n }\n\n return new ExtractorConfig({ ...extractorConfigParameters, tsdocConfigFile, tsdocConfiguration });\n }\n\n /**\n * Gets the report configuration for the \"complete\" (default) report configuration, if one was specified.\n */\n private _getCompleteReportConfig(): IExtractorConfigApiReport | undefined {\n return this.reportConfigs.find((x) => x.variant === 'complete');\n }\n\n private static _resolvePathWithTokens(\n fieldName: string,\n value: string | undefined,\n tokenContext: IExtractorConfigTokenContext\n ): string {\n value = ExtractorConfig._expandStringWithTokens(fieldName, value, tokenContext);\n if (value !== '') {\n value = path.resolve(tokenContext.projectFolder, value);\n }\n return value;\n }\n\n private static _expandStringWithTokens(\n fieldName: string,\n value: string | undefined,\n tokenContext: IExtractorConfigTokenContext\n ): string {\n value = value ? value.trim() : '';\n if (value !== '') {\n value = Text.replaceAll(value, '<unscopedPackageName>', tokenContext.unscopedPackageName);\n value = Text.replaceAll(value, '<packageName>', tokenContext.packageName);\n\n const projectFolderToken: string = '<projectFolder>';\n if (value.indexOf(projectFolderToken) === 0) {\n // Replace \"<projectFolder>\" at the start of a string\n value = path.join(tokenContext.projectFolder, value.substr(projectFolderToken.length));\n }\n\n if (value.indexOf(projectFolderToken) >= 0) {\n // If after all replacements, \"<projectFolder>\" appears somewhere in the string, report an error\n throw new Error(\n `The \"${fieldName}\" value incorrectly uses the \"<projectFolder>\" token.` +\n ` It must appear at the start of the string.`\n );\n }\n\n if (value.indexOf('<lookup>') >= 0) {\n throw new Error(`The \"${fieldName}\" value incorrectly uses the \"<lookup>\" token`);\n }\n ExtractorConfig._rejectAnyTokensInPath(value, fieldName);\n }\n return value;\n }\n\n /**\n * Returns true if the specified file path has the \".d.ts\" file extension.\n */\n public static hasDtsFileExtension(filePath: string): boolean {\n return ExtractorConfig._declarationFileExtensionRegExp.test(filePath);\n }\n\n /**\n * Given a path string that may have originally contained expandable tokens such as `<projectFolder>\"`\n * this reports an error if any token-looking substrings remain after expansion (e.g. `c:\\blah\\<invalid>\\blah`).\n */\n private static _rejectAnyTokensInPath(value: string, fieldName: string): void {\n if (value.indexOf('<') < 0 && value.indexOf('>') < 0) {\n return;\n }\n\n // Can we determine the name of a token?\n const tokenRegExp: RegExp = /(\\<[^<]*?\\>)/;\n const match: RegExpExecArray | null = tokenRegExp.exec(value);\n if (match) {\n throw new Error(`The \"${fieldName}\" value contains an unrecognized token \"${match[1]}\"`);\n }\n throw new Error(`The \"${fieldName}\" value contains extra token characters (\"<\" or \">\"): ${value}`);\n }\n}\n"]}
1
+ {"version":3,"file":"ExtractorConfig.js","sourceRoot":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AChC,CAAC;AACH,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.\n// See LICENSE in the project root for license information.\n\nimport * as path from 'path';\nimport * as resolve from 'resolve';\nimport lodash = require('lodash');\nimport {\n JsonFile,\n JsonSchema,\n FileSystem,\n PackageJsonLookup,\n type INodePackageJson,\n PackageName,\n Text,\n InternalError,\n Path,\n NewlineKind\n} from '@rushstack/node-core-library';\nimport { type IRigConfig, RigConfig } from '@rushstack/rig-package';\nimport { EnumMemberOrder, ReleaseTag } from '@microsoft/api-extractor-model';\nimport { TSDocConfiguration, TSDocTagDefinition } from '@microsoft/tsdoc';\nimport { TSDocConfigFile } from '@microsoft/tsdoc-config';\n\nimport type {\n ApiReportVariant,\n IConfigApiReport,\n IConfigFile,\n IExtractorMessagesConfig\n} from './IConfigFile';\nimport { PackageMetadataManager } from '../analyzer/PackageMetadataManager';\nimport { MessageRouter } from '../collector/MessageRouter';\nimport type { IApiModelGenerationOptions } from '../generators/ApiModelGenerator';\n\nimport apiExtractorSchema from '../schemas/api-extractor.schema.json';\n\n/**\n * Tokens used during variable expansion of path fields from api-extractor.json.\n */\ninterface IExtractorConfigTokenContext {\n /**\n * The `<unscopedPackageName>` token returns the project's NPM package name, without any NPM scope.\n * If there is no associated package.json file, then the value is `unknown-package`.\n *\n * Example: `my-project`\n */\n unscopedPackageName: string;\n\n /**\n * The `<packageName>` token returns the project's full NPM package name including any NPM scope.\n * If there is no associated package.json file, then the value is `unknown-package`.\n *\n * Example: `@scope/my-project`\n */\n packageName: string;\n\n /**\n * The `<projectFolder>` token returns the expanded `\"projectFolder\"` setting from api-extractor.json.\n */\n projectFolder: string;\n}\n\n/**\n * Options for {@link ExtractorConfig.tryLoadForFolder}.\n *\n * @public\n */\nexport interface IExtractorConfigLoadForFolderOptions {\n /**\n * The folder path to start from when searching for api-extractor.json.\n */\n startingFolder: string;\n\n /**\n * An already constructed `PackageJsonLookup` cache object to use. If omitted, a temporary one will\n * be constructed.\n */\n packageJsonLookup?: PackageJsonLookup;\n\n /**\n * An already constructed `RigConfig` object. If omitted, then a new `RigConfig` object will be constructed.\n */\n rigConfig?: IRigConfig;\n}\n\n/**\n * Options for {@link ExtractorConfig.prepare}.\n *\n * @public\n */\nexport interface IExtractorConfigPrepareOptions {\n /**\n * A configuration object as returned by {@link ExtractorConfig.loadFile}.\n */\n configObject: IConfigFile;\n\n /**\n * The absolute path of the file that the `configObject` object was loaded from. This is used for error messages\n * and when probing for `tsconfig.json`.\n *\n * @remarks\n *\n * If `configObjectFullPath` and `projectFolderLookupToken` are both unspecified, then the api-extractor.json\n * config file must explicitly specify a `projectFolder` setting rather than relying on the `<lookup>` token.\n */\n configObjectFullPath: string | undefined;\n\n /**\n * The parsed package.json file for the working package, or undefined if API Extractor was invoked without\n * a package.json file.\n *\n * @remarks\n *\n * If omitted, then the `<unscopedPackageName>` and `<packageName>` tokens will have default values.\n */\n packageJson?: INodePackageJson | undefined;\n\n /**\n * The absolute path of the file that the `packageJson` object was loaded from, or undefined if API Extractor\n * was invoked without a package.json file.\n *\n * @remarks\n *\n * This is used for error messages and when resolving paths found in package.json.\n *\n * If `packageJsonFullPath` is specified but `packageJson` is omitted, the file will be loaded automatically.\n */\n packageJsonFullPath: string | undefined;\n\n /**\n * The default value for the `projectFolder` setting is the `<lookup>` token, which uses a heuristic to guess\n * an appropriate project folder. Use `projectFolderLookupValue` to manually specify the `<lookup>` token value\n * instead.\n *\n * @remarks\n * If the `projectFolder` setting is explicitly specified in api-extractor.json file, it should take precedence\n * over a value specified via the API. Thus the `projectFolderLookupToken` option provides a way to override\n * the default value for `projectFolder` setting while still honoring a manually specified value.\n */\n projectFolderLookupToken?: string;\n\n /**\n * Allow customization of the tsdoc.json config file. If omitted, this file will be loaded from its default\n * location. If the file does not exist, then the standard definitions will be used from\n * `@microsoft/api-extractor/extends/tsdoc-base.json`.\n */\n tsdocConfigFile?: TSDocConfigFile;\n\n /**\n * When preparing the configuration object, folder and file paths referenced in the configuration are checked\n * for existence, and an error is reported if they are not found. This option can be used to disable this\n * check for the main entry point module. This may be useful when preparing a configuration file for an\n * un-built project.\n */\n ignoreMissingEntryPoint?: boolean;\n}\n\n/**\n * Configuration for a single API report, including its {@link IExtractorConfigApiReport.variant}.\n *\n * @public\n */\nexport interface IExtractorConfigApiReport {\n /**\n * Report variant.\n * Determines which API items will be included in the report output, based on their tagged release levels.\n */\n variant: ApiReportVariant;\n\n /**\n * Name of the output report file.\n * @remarks Relative to the configured report directory path.\n */\n fileName: string;\n}\n\n/** Default {@link IConfigApiReport.reportVariants} */\nconst defaultApiReportVariants: readonly ApiReportVariant[] = ['complete'];\n\n/**\n * Default {@link IConfigApiReport.tagsToReport}.\n *\n * @remarks\n * Note that this list is externally documented, and directly affects report output.\n * Also note that the order of tags in this list is significant, as it determines the order of tags in the report.\n * Any changes to this list should be considered breaking.\n */\nconst defaultTagsToReport: Readonly<Record<`@${string}`, boolean>> = {\n '@sealed': true,\n '@virtual': true,\n '@override': true,\n '@eventProperty': true,\n '@deprecated': true\n};\n\ninterface IExtractorConfigParameters {\n projectFolder: string;\n packageJson: INodePackageJson | undefined;\n packageFolder: string | undefined;\n mainEntryPointFilePath: string;\n bundledPackages: string[];\n tsconfigFilePath: string;\n overrideTsconfig: {} | undefined;\n skipLibCheck: boolean;\n apiReportEnabled: boolean;\n reportConfigs: readonly IExtractorConfigApiReport[];\n reportFolder: string;\n reportTempFolder: string;\n apiReportIncludeForgottenExports: boolean;\n tagsToReport: Readonly<Record<`@${string}`, boolean>>;\n docModelGenerationOptions: IApiModelGenerationOptions | undefined;\n apiJsonFilePath: string;\n docModelIncludeForgottenExports: boolean;\n projectFolderUrl: string | undefined;\n rollupEnabled: boolean;\n untrimmedFilePath: string;\n alphaTrimmedFilePath: string;\n betaTrimmedFilePath: string;\n publicTrimmedFilePath: string;\n omitTrimmingComments: boolean;\n tsdocMetadataEnabled: boolean;\n tsdocMetadataFilePath: string;\n tsdocConfigFile: TSDocConfigFile;\n tsdocConfiguration: TSDocConfiguration;\n newlineKind: NewlineKind;\n messages: IExtractorMessagesConfig;\n testMode: boolean;\n enumMemberOrder: EnumMemberOrder;\n}\n\n/**\n * The `ExtractorConfig` class loads, validates, interprets, and represents the api-extractor.json config file.\n * @sealed\n * @public\n */\nexport class ExtractorConfig {\n /**\n * The JSON Schema for API Extractor config file (api-extractor.schema.json).\n */\n public static readonly jsonSchema: JsonSchema = JsonSchema.fromLoadedObject(apiExtractorSchema);\n\n /**\n * The config file name \"api-extractor.json\".\n */\n public static readonly FILENAME: 'api-extractor.json' = 'api-extractor.json';\n\n /**\n * The full path to `extends/tsdoc-base.json` which contains the standard TSDoc configuration\n * for API Extractor.\n * @internal\n */\n public static readonly _tsdocBaseFilePath: string = path.resolve(\n __dirname,\n '../../extends/tsdoc-base.json'\n );\n\n private static readonly _defaultConfig: Partial<IConfigFile> = JsonFile.load(\n path.join(__dirname, '../schemas/api-extractor-defaults.json')\n );\n\n /** Match all three flavors for type declaration files (.d.ts, .d.mts, .d.cts) */\n private static readonly _declarationFileExtensionRegExp: RegExp = /\\.d\\.(c|m)?ts$/i;\n\n /** {@inheritDoc IConfigFile.projectFolder} */\n public readonly projectFolder: string;\n\n /**\n * The parsed package.json file for the working package, or undefined if API Extractor was invoked without\n * a package.json file.\n */\n public readonly packageJson: INodePackageJson | undefined;\n\n /**\n * The absolute path of the folder containing the package.json file for the working package, or undefined\n * if API Extractor was invoked without a package.json file.\n */\n public readonly packageFolder: string | undefined;\n\n /** {@inheritDoc IConfigFile.mainEntryPointFilePath} */\n public readonly mainEntryPointFilePath: string;\n\n /** {@inheritDoc IConfigFile.bundledPackages} */\n public readonly bundledPackages: string[];\n\n /** {@inheritDoc IConfigCompiler.tsconfigFilePath} */\n public readonly tsconfigFilePath: string;\n\n /** {@inheritDoc IConfigCompiler.overrideTsconfig} */\n public readonly overrideTsconfig: {} | undefined;\n\n /** {@inheritDoc IConfigCompiler.skipLibCheck} */\n public readonly skipLibCheck: boolean;\n\n /** {@inheritDoc IConfigApiReport.enabled} */\n public readonly apiReportEnabled: boolean;\n\n /**\n * List of configurations for report files to be generated.\n * @remarks Derived from {@link IConfigApiReport.reportFileName} and {@link IConfigApiReport.reportVariants}.\n */\n public readonly reportConfigs: readonly IExtractorConfigApiReport[];\n /** {@inheritDoc IConfigApiReport.reportFolder} */\n public readonly reportFolder: string;\n /** {@inheritDoc IConfigApiReport.reportTempFolder} */\n public readonly reportTempFolder: string;\n /** {@inheritDoc IConfigApiReport.tagsToReport} */\n public readonly tagsToReport: Readonly<Record<`@${string}`, boolean>>;\n\n /**\n * Gets the file path for the \"complete\" (default) report configuration, if one was specified.\n * Otherwise, returns an empty string.\n * @deprecated Use {@link ExtractorConfig.reportConfigs} to access all report configurations.\n */\n public get reportFilePath(): string {\n const completeConfig: IExtractorConfigApiReport | undefined = this._getCompleteReportConfig();\n return completeConfig === undefined ? '' : path.join(this.reportFolder, completeConfig.fileName);\n }\n\n /**\n * Gets the temp file path for the \"complete\" (default) report configuration, if one was specified.\n * Otherwise, returns an empty string.\n * @deprecated Use {@link ExtractorConfig.reportConfigs} to access all report configurations.\n */\n public get reportTempFilePath(): string {\n const completeConfig: IExtractorConfigApiReport | undefined = this._getCompleteReportConfig();\n return completeConfig === undefined ? '' : path.join(this.reportTempFolder, completeConfig.fileName);\n }\n\n /** {@inheritDoc IConfigApiReport.includeForgottenExports} */\n public readonly apiReportIncludeForgottenExports: boolean;\n\n /**\n * If specified, the doc model is enabled and the specified options will be used.\n * @beta\n */\n public readonly docModelGenerationOptions: IApiModelGenerationOptions | undefined;\n /** {@inheritDoc IConfigDocModel.apiJsonFilePath} */\n public readonly apiJsonFilePath: string;\n /** {@inheritDoc IConfigDocModel.includeForgottenExports} */\n public readonly docModelIncludeForgottenExports: boolean;\n /** {@inheritDoc IConfigDocModel.projectFolderUrl} */\n public readonly projectFolderUrl: string | undefined;\n\n /** {@inheritDoc IConfigDtsRollup.enabled} */\n public readonly rollupEnabled: boolean;\n /** {@inheritDoc IConfigDtsRollup.untrimmedFilePath} */\n public readonly untrimmedFilePath: string;\n /** {@inheritDoc IConfigDtsRollup.alphaTrimmedFilePath} */\n public readonly alphaTrimmedFilePath: string;\n /** {@inheritDoc IConfigDtsRollup.betaTrimmedFilePath} */\n public readonly betaTrimmedFilePath: string;\n /** {@inheritDoc IConfigDtsRollup.publicTrimmedFilePath} */\n public readonly publicTrimmedFilePath: string;\n /** {@inheritDoc IConfigDtsRollup.omitTrimmingComments} */\n public readonly omitTrimmingComments: boolean;\n\n /** {@inheritDoc IConfigTsdocMetadata.enabled} */\n public readonly tsdocMetadataEnabled: boolean;\n /** {@inheritDoc IConfigTsdocMetadata.tsdocMetadataFilePath} */\n public readonly tsdocMetadataFilePath: string;\n\n /**\n * The tsdoc.json configuration that will be used when parsing doc comments.\n */\n public readonly tsdocConfigFile: TSDocConfigFile;\n\n /**\n * The `TSDocConfiguration` loaded from {@link ExtractorConfig.tsdocConfigFile}.\n */\n public readonly tsdocConfiguration: TSDocConfiguration;\n\n /**\n * Specifies what type of newlines API Extractor should use when writing output files. By default, the output files\n * will be written with Windows-style newlines.\n */\n public readonly newlineKind: NewlineKind;\n\n /** {@inheritDoc IConfigFile.messages} */\n public readonly messages: IExtractorMessagesConfig;\n\n /** {@inheritDoc IConfigFile.testMode} */\n public readonly testMode: boolean;\n\n /** {@inheritDoc IConfigFile.enumMemberOrder} */\n public readonly enumMemberOrder: EnumMemberOrder;\n\n private constructor({\n projectFolder,\n packageJson,\n packageFolder,\n mainEntryPointFilePath,\n bundledPackages,\n tsconfigFilePath,\n overrideTsconfig,\n skipLibCheck,\n apiReportEnabled,\n apiReportIncludeForgottenExports,\n reportConfigs,\n reportFolder,\n reportTempFolder,\n tagsToReport,\n docModelGenerationOptions,\n apiJsonFilePath,\n docModelIncludeForgottenExports,\n projectFolderUrl,\n rollupEnabled,\n untrimmedFilePath,\n alphaTrimmedFilePath,\n betaTrimmedFilePath,\n publicTrimmedFilePath,\n omitTrimmingComments,\n tsdocMetadataEnabled,\n tsdocMetadataFilePath,\n tsdocConfigFile,\n tsdocConfiguration,\n newlineKind,\n messages,\n testMode,\n enumMemberOrder\n }: IExtractorConfigParameters) {\n this.projectFolder = projectFolder;\n this.packageJson = packageJson;\n this.packageFolder = packageFolder;\n this.mainEntryPointFilePath = mainEntryPointFilePath;\n this.bundledPackages = bundledPackages;\n this.tsconfigFilePath = tsconfigFilePath;\n this.overrideTsconfig = overrideTsconfig;\n this.skipLibCheck = skipLibCheck;\n this.apiReportEnabled = apiReportEnabled;\n this.apiReportIncludeForgottenExports = apiReportIncludeForgottenExports;\n this.reportConfigs = reportConfigs;\n this.reportFolder = reportFolder;\n this.reportTempFolder = reportTempFolder;\n this.tagsToReport = tagsToReport;\n this.docModelGenerationOptions = docModelGenerationOptions;\n this.apiJsonFilePath = apiJsonFilePath;\n this.docModelIncludeForgottenExports = docModelIncludeForgottenExports;\n this.projectFolderUrl = projectFolderUrl;\n this.rollupEnabled = rollupEnabled;\n this.untrimmedFilePath = untrimmedFilePath;\n this.alphaTrimmedFilePath = alphaTrimmedFilePath;\n this.betaTrimmedFilePath = betaTrimmedFilePath;\n this.publicTrimmedFilePath = publicTrimmedFilePath;\n this.omitTrimmingComments = omitTrimmingComments;\n this.tsdocMetadataEnabled = tsdocMetadataEnabled;\n this.tsdocMetadataFilePath = tsdocMetadataFilePath;\n this.tsdocConfigFile = tsdocConfigFile;\n this.tsdocConfiguration = tsdocConfiguration;\n this.newlineKind = newlineKind;\n this.messages = messages;\n this.testMode = testMode;\n this.enumMemberOrder = enumMemberOrder;\n }\n\n /**\n * Returns a JSON-like string representing the `ExtractorConfig` state, which can be printed to a console\n * for diagnostic purposes.\n *\n * @remarks\n * This is used by the \"--diagnostics\" command-line option. The string is not intended to be deserialized;\n * its format may be changed at any time.\n */\n public getDiagnosticDump(): string {\n // Handle the simple JSON-serializable properties using buildJsonDumpObject()\n const result: object = MessageRouter.buildJsonDumpObject(this, {\n keyNamesToOmit: ['tsdocConfigFile', 'tsdocConfiguration']\n });\n\n // Implement custom formatting for tsdocConfigFile and tsdocConfiguration\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n (result as any).tsdocConfigFile = {\n filePath: this.tsdocConfigFile.filePath,\n log: this.tsdocConfigFile.log.messages.map((x) => x.toString())\n };\n\n return JSON.stringify(result, undefined, 2);\n }\n\n /**\n * Returns a simplified file path for use in error messages.\n * @internal\n */\n public _getShortFilePath(absolutePath: string): string {\n if (!path.isAbsolute(absolutePath)) {\n throw new InternalError('Expected absolute path: ' + absolutePath);\n }\n if (Path.isUnderOrEqual(absolutePath, this.projectFolder)) {\n return Path.convertToSlashes(path.relative(this.projectFolder, absolutePath));\n }\n return absolutePath;\n }\n\n /**\n * Searches for the api-extractor.json config file associated with the specified starting folder,\n * and loads the file if found. This lookup supports\n * {@link https://www.npmjs.com/package/@rushstack/rig-package | rig packages}.\n *\n * @remarks\n * The search will first look for a package.json file in a parent folder of the starting folder;\n * if found, that will be used as the base folder instead of the starting folder. If the config\n * file is not found in `<baseFolder>/api-extractor.json` or `<baseFolder>/config/api-extractor.json`,\n * then `<baseFolder/config/rig.json` will be checked to see whether a\n * {@link https://www.npmjs.com/package/@rushstack/rig-package | rig package} is referenced; if so then\n * the rig's api-extractor.json file will be used instead. If a config file is found, it will be loaded\n * and returned with the `IExtractorConfigPrepareOptions` object. Otherwise, `undefined` is returned\n * to indicate that API Extractor does not appear to be configured for the specified folder.\n *\n * @returns An options object that can be passed to {@link ExtractorConfig.prepare}, or `undefined`\n * if not api-extractor.json file was found.\n */\n public static tryLoadForFolder(\n options: IExtractorConfigLoadForFolderOptions\n ): IExtractorConfigPrepareOptions | undefined {\n const packageJsonLookup: PackageJsonLookup = options.packageJsonLookup || new PackageJsonLookup();\n const startingFolder: string = options.startingFolder;\n\n // Figure out which project we're in and look for the config file at the project root\n const packageJsonFullPath: string | undefined =\n packageJsonLookup.tryGetPackageJsonFilePathFor(startingFolder);\n const packageFolder: string | undefined = packageJsonFullPath\n ? path.dirname(packageJsonFullPath)\n : undefined;\n\n // If there is no package, then just use the starting folder\n const baseFolder: string = packageFolder || startingFolder;\n\n let projectFolderLookupToken: string | undefined = undefined;\n\n // First try the standard \"config\" subfolder:\n let configFilename: string = path.join(baseFolder, 'config', ExtractorConfig.FILENAME);\n if (FileSystem.exists(configFilename)) {\n if (FileSystem.exists(path.join(baseFolder, ExtractorConfig.FILENAME))) {\n throw new Error(`Found conflicting ${ExtractorConfig.FILENAME} files in \".\" and \"./config\" folders`);\n }\n } else {\n // Otherwise try the top-level folder\n configFilename = path.join(baseFolder, ExtractorConfig.FILENAME);\n\n if (!FileSystem.exists(configFilename)) {\n // If We didn't find it in <packageFolder>/api-extractor.json or <packageFolder>/config/api-extractor.json\n // then check for a rig package\n if (packageFolder) {\n let rigConfig: IRigConfig;\n if (options.rigConfig) {\n // The caller provided an already solved RigConfig. Double-check that it is for the right project.\n if (!Path.isEqual(options.rigConfig.projectFolderPath, packageFolder)) {\n throw new Error(\n 'The provided ILoadForFolderOptions.rigConfig is for the wrong project folder:\\n' +\n '\\nExpected path: ' +\n packageFolder +\n '\\nProvided path: ' +\n options.rigConfig.projectFolderOriginalPath\n );\n }\n rigConfig = options.rigConfig;\n } else {\n rigConfig = RigConfig.loadForProjectFolder({\n projectFolderPath: packageFolder\n });\n }\n\n if (rigConfig.rigFound) {\n configFilename = path.join(rigConfig.getResolvedProfileFolder(), ExtractorConfig.FILENAME);\n\n // If the \"projectFolder\" setting isn't specified in api-extractor.json, it defaults to the\n // \"<lookup>\" token which will probe for the tsconfig.json nearest to the api-extractor.json path.\n // But this won't work if api-extractor.json belongs to the rig. So instead \"<lookup>\" should be\n // the \"<packageFolder>\" that referenced the rig.\n projectFolderLookupToken = packageFolder;\n }\n }\n if (!FileSystem.exists(configFilename)) {\n // API Extractor does not seem to be configured for this folder\n return undefined;\n }\n }\n }\n\n const configObjectFullPath: string = path.resolve(configFilename);\n const configObject: IConfigFile = ExtractorConfig.loadFile(configObjectFullPath);\n\n return {\n configObject,\n configObjectFullPath,\n packageJsonFullPath,\n projectFolderLookupToken\n };\n }\n\n /**\n * Loads the api-extractor.json config file from the specified file path, and prepares an `ExtractorConfig` object.\n *\n * @remarks\n * Loads the api-extractor.json config file from the specified file path. If the \"extends\" field is present,\n * the referenced file(s) will be merged. For any omitted fields, the API Extractor default values are merged.\n *\n * The result is prepared using `ExtractorConfig.prepare()`.\n */\n public static loadFileAndPrepare(configJsonFilePath: string): ExtractorConfig {\n const configObjectFullPath: string = path.resolve(configJsonFilePath);\n const configObject: IConfigFile = ExtractorConfig.loadFile(configObjectFullPath);\n\n const packageJsonLookup: PackageJsonLookup = new PackageJsonLookup();\n const packageJsonFullPath: string | undefined =\n packageJsonLookup.tryGetPackageJsonFilePathFor(configObjectFullPath);\n\n const extractorConfig: ExtractorConfig = ExtractorConfig.prepare({\n configObject,\n configObjectFullPath,\n packageJsonFullPath\n });\n\n return extractorConfig;\n }\n\n /**\n * Performs only the first half of {@link ExtractorConfig.loadFileAndPrepare}, providing an opportunity to\n * modify the object before it is passed to {@link ExtractorConfig.prepare}.\n *\n * @remarks\n * Loads the api-extractor.json config file from the specified file path. If the \"extends\" field is present,\n * the referenced file(s) will be merged. For any omitted fields, the API Extractor default values are merged.\n */\n public static loadFile(jsonFilePath: string): IConfigFile {\n // Set to keep track of config files which have been processed.\n const visitedPaths: Set<string> = new Set<string>();\n\n let currentConfigFilePath: string = path.resolve(jsonFilePath);\n let configObject: Partial<IConfigFile> = {};\n\n // Lodash merges array values by default, which is unintuitive for config files (and makes it impossible for derived configurations to overwrite arrays).\n // For example, given a base config containing an array property with value [\"foo\", \"bar\"] and a derived config that specifies [\"baz\"] for that property, lodash will produce [\"baz\", \"bar\"], which is unintuitive.\n // This customizer function ensures that arrays are always overwritten.\n const mergeCustomizer: lodash.MergeWithCustomizer = (objValue, srcValue) => {\n if (Array.isArray(srcValue)) {\n return srcValue;\n }\n // Fall back to default merge behavior.\n return undefined;\n };\n\n try {\n do {\n // Check if this file was already processed.\n if (visitedPaths.has(currentConfigFilePath)) {\n throw new Error(\n `The API Extractor \"extends\" setting contains a cycle.` +\n ` This file is included twice: \"${currentConfigFilePath}\"`\n );\n }\n visitedPaths.add(currentConfigFilePath);\n\n const currentConfigFolderPath: string = path.dirname(currentConfigFilePath);\n\n // Load the extractor config defined in extends property.\n const baseConfig: IConfigFile = JsonFile.load(currentConfigFilePath);\n\n let extendsField: string = baseConfig.extends || '';\n\n // Delete the \"extends\" field so it doesn't get merged\n delete baseConfig.extends;\n\n if (extendsField) {\n if (extendsField.match(/^\\.\\.?[\\\\/]/)) {\n // EXAMPLE: \"./subfolder/api-extractor-base.json\"\n extendsField = path.resolve(currentConfigFolderPath, extendsField);\n } else {\n // EXAMPLE: \"my-package/api-extractor-base.json\"\n //\n // Resolve \"my-package\" from the perspective of the current folder.\n try {\n extendsField = resolve.sync(extendsField, {\n basedir: currentConfigFolderPath\n });\n } catch (e) {\n throw new Error(`Error resolving NodeJS path \"${extendsField}\": ${(e as Error).message}`);\n }\n }\n }\n\n // This step has to be performed in advance, since the currentConfigFolderPath information will be lost\n // after lodash.merge() is performed.\n ExtractorConfig._resolveConfigFileRelativePaths(baseConfig, currentConfigFolderPath);\n\n // Merge extractorConfig into baseConfig, mutating baseConfig\n lodash.mergeWith(baseConfig, configObject, mergeCustomizer);\n configObject = baseConfig;\n\n currentConfigFilePath = extendsField;\n } while (currentConfigFilePath);\n } catch (e) {\n throw new Error(`Error loading ${currentConfigFilePath}:\\n` + (e as Error).message);\n }\n\n // Lastly, apply the defaults\n configObject = lodash.mergeWith(\n lodash.cloneDeep(ExtractorConfig._defaultConfig),\n configObject,\n mergeCustomizer\n );\n\n ExtractorConfig.jsonSchema.validateObject(configObject, jsonFilePath);\n\n // The schema validation should ensure that this object conforms to IConfigFile\n return configObject as IConfigFile;\n }\n\n private static _resolveConfigFileRelativePaths(\n configFile: IConfigFile,\n currentConfigFolderPath: string\n ): void {\n if (configFile.projectFolder) {\n configFile.projectFolder = ExtractorConfig._resolveConfigFileRelativePath(\n 'projectFolder',\n configFile.projectFolder,\n currentConfigFolderPath\n );\n }\n\n if (configFile.mainEntryPointFilePath) {\n configFile.mainEntryPointFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'mainEntryPointFilePath',\n configFile.mainEntryPointFilePath,\n currentConfigFolderPath\n );\n }\n\n if (configFile.compiler) {\n if (configFile.compiler.tsconfigFilePath) {\n configFile.compiler.tsconfigFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'tsconfigFilePath',\n configFile.compiler.tsconfigFilePath,\n currentConfigFolderPath\n );\n }\n }\n\n if (configFile.apiReport) {\n if (configFile.apiReport.reportFolder) {\n configFile.apiReport.reportFolder = ExtractorConfig._resolveConfigFileRelativePath(\n 'reportFolder',\n configFile.apiReport.reportFolder,\n currentConfigFolderPath\n );\n }\n if (configFile.apiReport.reportTempFolder) {\n configFile.apiReport.reportTempFolder = ExtractorConfig._resolveConfigFileRelativePath(\n 'reportTempFolder',\n configFile.apiReport.reportTempFolder,\n currentConfigFolderPath\n );\n }\n }\n\n if (configFile.docModel) {\n if (configFile.docModel.apiJsonFilePath) {\n configFile.docModel.apiJsonFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'apiJsonFilePath',\n configFile.docModel.apiJsonFilePath,\n currentConfigFolderPath\n );\n }\n }\n\n if (configFile.dtsRollup) {\n if (configFile.dtsRollup.untrimmedFilePath) {\n configFile.dtsRollup.untrimmedFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'untrimmedFilePath',\n configFile.dtsRollup.untrimmedFilePath,\n currentConfigFolderPath\n );\n }\n if (configFile.dtsRollup.alphaTrimmedFilePath) {\n configFile.dtsRollup.alphaTrimmedFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'alphaTrimmedFilePath',\n configFile.dtsRollup.alphaTrimmedFilePath,\n currentConfigFolderPath\n );\n }\n if (configFile.dtsRollup.betaTrimmedFilePath) {\n configFile.dtsRollup.betaTrimmedFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'betaTrimmedFilePath',\n configFile.dtsRollup.betaTrimmedFilePath,\n currentConfigFolderPath\n );\n }\n if (configFile.dtsRollup.publicTrimmedFilePath) {\n configFile.dtsRollup.publicTrimmedFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'publicTrimmedFilePath',\n configFile.dtsRollup.publicTrimmedFilePath,\n currentConfigFolderPath\n );\n }\n }\n\n if (configFile.tsdocMetadata) {\n if (configFile.tsdocMetadata.tsdocMetadataFilePath) {\n configFile.tsdocMetadata.tsdocMetadataFilePath = ExtractorConfig._resolveConfigFileRelativePath(\n 'tsdocMetadataFilePath',\n configFile.tsdocMetadata.tsdocMetadataFilePath,\n currentConfigFolderPath\n );\n }\n }\n }\n\n private static _resolveConfigFileRelativePath(\n fieldName: string,\n fieldValue: string,\n currentConfigFolderPath: string\n ): string {\n if (!path.isAbsolute(fieldValue)) {\n if (fieldValue.indexOf('<projectFolder>') !== 0) {\n // If the path is not absolute and does not start with \"<projectFolder>\", then resolve it relative\n // to the folder of the config file that it appears in\n return path.join(currentConfigFolderPath, fieldValue);\n }\n }\n\n return fieldValue;\n }\n\n /**\n * Prepares an `ExtractorConfig` object using a configuration that is provided as a runtime object,\n * rather than reading it from disk. This allows configurations to be constructed programmatically,\n * loaded from an alternate source, and/or customized after loading.\n */\n public static prepare(options: IExtractorConfigPrepareOptions): ExtractorConfig {\n const filenameForErrors: string = options.configObjectFullPath || 'the configuration object';\n const configObject: Partial<IConfigFile> = options.configObject;\n\n if (configObject.extends) {\n throw new Error(\n 'The IConfigFile.extends field must be expanded before calling ExtractorConfig.prepare()'\n );\n }\n\n if (options.configObjectFullPath) {\n if (!path.isAbsolute(options.configObjectFullPath)) {\n throw new Error('The \"configObjectFullPath\" setting must be an absolute path');\n }\n }\n\n ExtractorConfig.jsonSchema.validateObject(configObject, filenameForErrors);\n\n const packageJsonFullPath: string | undefined = options.packageJsonFullPath;\n let packageFolder: string | undefined = undefined;\n let packageJson: INodePackageJson | undefined = undefined;\n\n if (packageJsonFullPath) {\n if (!/.json$/i.test(packageJsonFullPath)) {\n // Catch common mistakes e.g. where someone passes a folder path instead of a file path\n throw new Error('The \"packageJsonFullPath\" setting does not have a .json file extension');\n }\n if (!path.isAbsolute(packageJsonFullPath)) {\n throw new Error('The \"packageJsonFullPath\" setting must be an absolute path');\n }\n\n if (options.packageJson) {\n packageJson = options.packageJson;\n } else {\n const packageJsonLookup: PackageJsonLookup = new PackageJsonLookup();\n packageJson = packageJsonLookup.loadNodePackageJson(packageJsonFullPath);\n }\n\n packageFolder = path.dirname(packageJsonFullPath);\n }\n\n // \"tsdocConfigFile\" and \"tsdocConfiguration\" are prepared outside the try-catch block,\n // so that if exceptions are thrown, it will not get the \"Error parsing api-extractor.json:\" header\n let extractorConfigParameters: Omit<IExtractorConfigParameters, 'tsdocConfigFile' | 'tsdocConfiguration'>;\n\n try {\n if (!configObject.compiler) {\n // A merged configuration should have this\n throw new Error('The \"compiler\" section is missing');\n }\n\n if (!configObject.projectFolder) {\n // A merged configuration should have this\n throw new Error('The \"projectFolder\" setting is missing');\n }\n\n let projectFolder: string;\n if (configObject.projectFolder.trim() === '<lookup>') {\n if (options.projectFolderLookupToken) {\n // Use the manually specified \"<lookup>\" value\n projectFolder = options.projectFolderLookupToken;\n\n if (!FileSystem.exists(options.projectFolderLookupToken)) {\n throw new Error(\n 'The specified \"projectFolderLookupToken\" path does not exist: ' +\n options.projectFolderLookupToken\n );\n }\n } else {\n if (!options.configObjectFullPath) {\n throw new Error(\n 'The \"projectFolder\" setting uses the \"<lookup>\" token, but it cannot be expanded because' +\n ' the \"configObjectFullPath\" setting was not specified'\n );\n }\n\n // \"The default value for `projectFolder` is the token `<lookup>`, which means the folder is determined\n // by traversing parent folders, starting from the folder containing api-extractor.json, and stopping\n // at the first folder that contains a tsconfig.json file. If a tsconfig.json file cannot be found in\n // this way, then an error will be reported.\"\n\n let currentFolder: string = path.dirname(options.configObjectFullPath);\n for (;;) {\n const tsconfigPath: string = path.join(currentFolder, 'tsconfig.json');\n if (FileSystem.exists(tsconfigPath)) {\n projectFolder = currentFolder;\n break;\n }\n const parentFolder: string = path.dirname(currentFolder);\n if (parentFolder === '' || parentFolder === currentFolder) {\n throw new Error(\n 'The \"projectFolder\" setting uses the \"<lookup>\" token, but a tsconfig.json file cannot be' +\n ' found in this folder or any parent folder.'\n );\n }\n currentFolder = parentFolder;\n }\n }\n } else {\n ExtractorConfig._rejectAnyTokensInPath(configObject.projectFolder, 'projectFolder');\n\n if (!FileSystem.exists(configObject.projectFolder)) {\n throw new Error('The specified \"projectFolder\" path does not exist: ' + configObject.projectFolder);\n }\n\n projectFolder = configObject.projectFolder;\n }\n\n const tokenContext: IExtractorConfigTokenContext = {\n unscopedPackageName: 'unknown-package',\n packageName: 'unknown-package',\n projectFolder: projectFolder\n };\n\n if (packageJson) {\n tokenContext.packageName = packageJson.name;\n tokenContext.unscopedPackageName = PackageName.getUnscopedName(packageJson.name);\n }\n\n if (!configObject.mainEntryPointFilePath) {\n // A merged configuration should have this\n throw new Error('The \"mainEntryPointFilePath\" setting is missing');\n }\n const mainEntryPointFilePath: string = ExtractorConfig._resolvePathWithTokens(\n 'mainEntryPointFilePath',\n configObject.mainEntryPointFilePath,\n tokenContext\n );\n\n if (!ExtractorConfig.hasDtsFileExtension(mainEntryPointFilePath)) {\n throw new Error(\n 'The \"mainEntryPointFilePath\" value is not a declaration file: ' + mainEntryPointFilePath\n );\n }\n\n if (!options.ignoreMissingEntryPoint && !FileSystem.exists(mainEntryPointFilePath)) {\n throw new Error('The \"mainEntryPointFilePath\" path does not exist: ' + mainEntryPointFilePath);\n }\n\n const bundledPackages: string[] = configObject.bundledPackages || [];\n\n // Note: we cannot fully validate package name patterns, as the strings may contain wildcards.\n // We won't know if the entries are valid until we can compare them against the package.json \"dependencies\" contents.\n\n const tsconfigFilePath: string = ExtractorConfig._resolvePathWithTokens(\n 'tsconfigFilePath',\n configObject.compiler.tsconfigFilePath,\n tokenContext\n );\n\n if (configObject.compiler.overrideTsconfig === undefined) {\n if (!tsconfigFilePath) {\n throw new Error('Either the \"tsconfigFilePath\" or \"overrideTsconfig\" setting must be specified');\n }\n if (!FileSystem.exists(tsconfigFilePath)) {\n throw new Error('The file referenced by \"tsconfigFilePath\" does not exist: ' + tsconfigFilePath);\n }\n }\n\n if (configObject.apiReport?.tagsToReport) {\n _validateTagsToReport(configObject.apiReport.tagsToReport);\n }\n\n const apiReportEnabled: boolean = configObject.apiReport?.enabled ?? false;\n const apiReportIncludeForgottenExports: boolean =\n configObject.apiReport?.includeForgottenExports ?? false;\n let reportFolder: string = tokenContext.projectFolder;\n let reportTempFolder: string = tokenContext.projectFolder;\n const reportConfigs: IExtractorConfigApiReport[] = [];\n let tagsToReport: Record<`@${string}`, boolean> = {};\n if (apiReportEnabled) {\n // Undefined case checked above where we assign `apiReportEnabled`\n const apiReportConfig: IConfigApiReport = configObject.apiReport!;\n\n const reportFileNameSuffix: string = '.api.md';\n let reportFileNameBase: string;\n if (apiReportConfig.reportFileName) {\n if (\n apiReportConfig.reportFileName.indexOf('/') >= 0 ||\n apiReportConfig.reportFileName.indexOf('\\\\') >= 0\n ) {\n throw new Error(\n `The \"reportFileName\" setting contains invalid characters: \"${apiReportConfig.reportFileName}\"`\n );\n }\n\n if (!apiReportConfig.reportFileName.endsWith(reportFileNameSuffix)) {\n // `.api.md` extension was not specified. Use provided file name base as is.\n reportFileNameBase = apiReportConfig.reportFileName;\n } else {\n // The system previously asked users to specify their filenames in a form containing the `.api.md` extension.\n // This guidance has changed, but to maintain backwards compatibility, we will temporarily support input\n // that ends with the `.api.md` extension specially, by stripping it out.\n // This should be removed in version 8, possibly replaced with an explicit error to help users\n // migrate their configs.\n reportFileNameBase = apiReportConfig.reportFileName.slice(0, -reportFileNameSuffix.length);\n }\n } else {\n // Default value\n reportFileNameBase = '<unscopedPackageName>';\n }\n\n const reportVariantKinds: readonly ApiReportVariant[] =\n apiReportConfig.reportVariants ?? defaultApiReportVariants;\n\n for (const reportVariantKind of reportVariantKinds) {\n // Omit the variant kind from the \"complete\" report file name for simplicity and for backwards compatibility.\n const fileNameWithTokens: string = `${reportFileNameBase}${\n reportVariantKind === 'complete' ? '' : `.${reportVariantKind}`\n }${reportFileNameSuffix}`;\n const normalizedFileName: string = ExtractorConfig._expandStringWithTokens(\n 'reportFileName',\n fileNameWithTokens,\n tokenContext\n );\n\n reportConfigs.push({\n fileName: normalizedFileName,\n variant: reportVariantKind\n });\n }\n\n if (apiReportConfig.reportFolder) {\n reportFolder = ExtractorConfig._resolvePathWithTokens(\n 'reportFolder',\n apiReportConfig.reportFolder,\n tokenContext\n );\n }\n\n if (apiReportConfig.reportTempFolder) {\n reportTempFolder = ExtractorConfig._resolvePathWithTokens(\n 'reportTempFolder',\n apiReportConfig.reportTempFolder,\n tokenContext\n );\n }\n\n tagsToReport = {\n ...defaultTagsToReport,\n ...apiReportConfig.tagsToReport\n };\n }\n\n let docModelGenerationOptions: IApiModelGenerationOptions | undefined = undefined;\n let apiJsonFilePath: string = '';\n let docModelIncludeForgottenExports: boolean = false;\n let projectFolderUrl: string | undefined;\n if (configObject.docModel?.enabled) {\n apiJsonFilePath = ExtractorConfig._resolvePathWithTokens(\n 'apiJsonFilePath',\n configObject.docModel.apiJsonFilePath,\n tokenContext\n );\n docModelIncludeForgottenExports = !!configObject.docModel.includeForgottenExports;\n projectFolderUrl = configObject.docModel.projectFolderUrl;\n\n const releaseTagsToTrim: Set<ReleaseTag> = new Set<ReleaseTag>();\n const releaseTagsToTrimOption: string[] = configObject.docModel.releaseTagsToTrim || ['@internal'];\n for (const releaseTagToTrim of releaseTagsToTrimOption) {\n let releaseTag: ReleaseTag;\n switch (releaseTagToTrim) {\n case '@internal': {\n releaseTag = ReleaseTag.Internal;\n break;\n }\n\n case '@alpha': {\n releaseTag = ReleaseTag.Alpha;\n break;\n }\n\n case '@beta': {\n releaseTag = ReleaseTag.Beta;\n break;\n }\n\n case '@public': {\n releaseTag = ReleaseTag.Public;\n break;\n }\n\n default: {\n throw new Error(`The release tag \"${releaseTagToTrim}\" is not supported`);\n }\n }\n\n releaseTagsToTrim.add(releaseTag);\n }\n\n docModelGenerationOptions = {\n releaseTagsToTrim\n };\n }\n\n let tsdocMetadataEnabled: boolean = false;\n let tsdocMetadataFilePath: string = '';\n if (configObject.tsdocMetadata) {\n tsdocMetadataEnabled = !!configObject.tsdocMetadata.enabled;\n\n if (tsdocMetadataEnabled) {\n tsdocMetadataFilePath = configObject.tsdocMetadata.tsdocMetadataFilePath || '';\n\n if (tsdocMetadataFilePath.trim() === '<lookup>') {\n if (!packageJson) {\n throw new Error(\n 'The \"<lookup>\" token cannot be used with the \"tsdocMetadataFilePath\" setting because' +\n ' the \"packageJson\" option was not provided'\n );\n }\n if (!packageJsonFullPath) {\n throw new Error(\n 'The \"<lookup>\" token cannot be used with \"tsdocMetadataFilePath\" because' +\n 'the \"packageJsonFullPath\" option was not provided'\n );\n }\n tsdocMetadataFilePath = PackageMetadataManager.resolveTsdocMetadataPath(\n path.dirname(packageJsonFullPath),\n packageJson\n );\n } else {\n tsdocMetadataFilePath = ExtractorConfig._resolvePathWithTokens(\n 'tsdocMetadataFilePath',\n configObject.tsdocMetadata.tsdocMetadataFilePath,\n tokenContext\n );\n }\n\n if (!tsdocMetadataFilePath) {\n throw new Error(\n 'The \"tsdocMetadata.enabled\" setting is enabled,' +\n ' but \"tsdocMetadataFilePath\" is not specified'\n );\n }\n }\n }\n\n let rollupEnabled: boolean = false;\n let untrimmedFilePath: string = '';\n let betaTrimmedFilePath: string = '';\n let alphaTrimmedFilePath: string = '';\n let publicTrimmedFilePath: string = '';\n let omitTrimmingComments: boolean = false;\n\n if (configObject.dtsRollup) {\n rollupEnabled = !!configObject.dtsRollup.enabled;\n untrimmedFilePath = ExtractorConfig._resolvePathWithTokens(\n 'untrimmedFilePath',\n configObject.dtsRollup.untrimmedFilePath,\n tokenContext\n );\n alphaTrimmedFilePath = ExtractorConfig._resolvePathWithTokens(\n 'alphaTrimmedFilePath',\n configObject.dtsRollup.alphaTrimmedFilePath,\n tokenContext\n );\n betaTrimmedFilePath = ExtractorConfig._resolvePathWithTokens(\n 'betaTrimmedFilePath',\n configObject.dtsRollup.betaTrimmedFilePath,\n tokenContext\n );\n publicTrimmedFilePath = ExtractorConfig._resolvePathWithTokens(\n 'publicTrimmedFilePath',\n configObject.dtsRollup.publicTrimmedFilePath,\n tokenContext\n );\n omitTrimmingComments = !!configObject.dtsRollup.omitTrimmingComments;\n }\n\n let newlineKind: NewlineKind;\n switch (configObject.newlineKind) {\n case 'lf':\n newlineKind = NewlineKind.Lf;\n break;\n case 'os':\n newlineKind = NewlineKind.OsDefault;\n break;\n default:\n newlineKind = NewlineKind.CrLf;\n break;\n }\n\n const enumMemberOrder: EnumMemberOrder = configObject.enumMemberOrder ?? EnumMemberOrder.ByName;\n\n extractorConfigParameters = {\n projectFolder: projectFolder,\n packageJson,\n packageFolder,\n mainEntryPointFilePath,\n bundledPackages,\n tsconfigFilePath,\n overrideTsconfig: configObject.compiler.overrideTsconfig,\n skipLibCheck: !!configObject.compiler.skipLibCheck,\n apiReportEnabled,\n reportConfigs,\n reportFolder,\n reportTempFolder,\n apiReportIncludeForgottenExports,\n tagsToReport,\n docModelGenerationOptions,\n apiJsonFilePath,\n docModelIncludeForgottenExports,\n projectFolderUrl,\n rollupEnabled,\n untrimmedFilePath,\n alphaTrimmedFilePath,\n betaTrimmedFilePath,\n publicTrimmedFilePath,\n omitTrimmingComments,\n tsdocMetadataEnabled,\n tsdocMetadataFilePath,\n newlineKind,\n messages: configObject.messages || {},\n testMode: !!configObject.testMode,\n enumMemberOrder\n };\n } catch (e) {\n throw new Error(`Error parsing ${filenameForErrors}:\\n` + (e as Error).message);\n }\n\n let tsdocConfigFile: TSDocConfigFile | undefined = options.tsdocConfigFile;\n\n if (!tsdocConfigFile) {\n // Example: \"my-project/tsdoc.json\"\n let packageTSDocConfigPath: string = TSDocConfigFile.findConfigPathForFolder(\n extractorConfigParameters.projectFolder\n );\n\n if (!packageTSDocConfigPath || !FileSystem.exists(packageTSDocConfigPath)) {\n // If the project does not have a tsdoc.json config file, then use API Extractor's base file.\n packageTSDocConfigPath = ExtractorConfig._tsdocBaseFilePath;\n if (!FileSystem.exists(packageTSDocConfigPath)) {\n throw new InternalError('Unable to load the built-in TSDoc config file: ' + packageTSDocConfigPath);\n }\n }\n tsdocConfigFile = TSDocConfigFile.loadFile(packageTSDocConfigPath);\n }\n\n // IMPORTANT: After calling TSDocConfigFile.loadFile(), we need to check for errors.\n if (tsdocConfigFile.hasErrors) {\n throw new Error(tsdocConfigFile.getErrorSummary());\n }\n\n const tsdocConfiguration: TSDocConfiguration = new TSDocConfiguration();\n tsdocConfigFile.configureParser(tsdocConfiguration);\n\n // IMPORTANT: After calling TSDocConfigFile.configureParser(), we need to check for errors a second time.\n if (tsdocConfigFile.hasErrors) {\n throw new Error(tsdocConfigFile.getErrorSummary());\n }\n\n return new ExtractorConfig({ ...extractorConfigParameters, tsdocConfigFile, tsdocConfiguration });\n }\n\n /**\n * Gets the report configuration for the \"complete\" (default) report configuration, if one was specified.\n */\n private _getCompleteReportConfig(): IExtractorConfigApiReport | undefined {\n return this.reportConfigs.find((x) => x.variant === 'complete');\n }\n\n private static _resolvePathWithTokens(\n fieldName: string,\n value: string | undefined,\n tokenContext: IExtractorConfigTokenContext\n ): string {\n value = ExtractorConfig._expandStringWithTokens(fieldName, value, tokenContext);\n if (value !== '') {\n value = path.resolve(tokenContext.projectFolder, value);\n }\n return value;\n }\n\n private static _expandStringWithTokens(\n fieldName: string,\n value: string | undefined,\n tokenContext: IExtractorConfigTokenContext\n ): string {\n value = value ? value.trim() : '';\n if (value !== '') {\n value = Text.replaceAll(value, '<unscopedPackageName>', tokenContext.unscopedPackageName);\n value = Text.replaceAll(value, '<packageName>', tokenContext.packageName);\n\n const projectFolderToken: string = '<projectFolder>';\n if (value.indexOf(projectFolderToken) === 0) {\n // Replace \"<projectFolder>\" at the start of a string\n value = path.join(tokenContext.projectFolder, value.substr(projectFolderToken.length));\n }\n\n if (value.indexOf(projectFolderToken) >= 0) {\n // If after all replacements, \"<projectFolder>\" appears somewhere in the string, report an error\n throw new Error(\n `The \"${fieldName}\" value incorrectly uses the \"<projectFolder>\" token.` +\n ` It must appear at the start of the string.`\n );\n }\n\n if (value.indexOf('<lookup>') >= 0) {\n throw new Error(`The \"${fieldName}\" value incorrectly uses the \"<lookup>\" token`);\n }\n ExtractorConfig._rejectAnyTokensInPath(value, fieldName);\n }\n return value;\n }\n\n /**\n * Returns true if the specified file path has the \".d.ts\" file extension.\n */\n public static hasDtsFileExtension(filePath: string): boolean {\n return ExtractorConfig._declarationFileExtensionRegExp.test(filePath);\n }\n\n /**\n * Given a path string that may have originally contained expandable tokens such as `<projectFolder>\"`\n * this reports an error if any token-looking substrings remain after expansion (e.g. `c:\\blah\\<invalid>\\blah`).\n */\n private static _rejectAnyTokensInPath(value: string, fieldName: string): void {\n if (value.indexOf('<') < 0 && value.indexOf('>') < 0) {\n return;\n }\n\n // Can we determine the name of a token?\n const tokenRegExp: RegExp = /(\\<[^<]*?\\>)/;\n const match: RegExpExecArray | null = tokenRegExp.exec(value);\n if (match) {\n throw new Error(`The \"${fieldName}\" value contains an unrecognized token \"${match[1]}\"`);\n }\n throw new Error(`The \"${fieldName}\" value contains extra token characters (\"<\" or \">\"): ${value}`);\n }\n}\n\nconst releaseTags: Set<string> = new Set(['@public', '@alpha', '@beta', '@internal']);\n\n/**\n * Validate {@link ExtractorConfig.tagsToReport}.\n */\nfunction _validateTagsToReport(\n tagsToReport: Record<string, boolean>\n): asserts tagsToReport is Record<`@${string}`, boolean> {\n const includedReleaseTags: string[] = [];\n const invalidTags: [string, string][] = []; // tag name, error\n for (const tag of Object.keys(tagsToReport)) {\n if (releaseTags.has(tag)) {\n // If a release tags is specified, regardless of whether it is enabled, we will throw an error.\n // Release tags must not be specified.\n includedReleaseTags.push(tag);\n }\n\n // If the tag is invalid, generate an error string from the inner error message.\n try {\n TSDocTagDefinition.validateTSDocTagName(tag);\n } catch (error) {\n invalidTags.push([tag, (error as Error).message]);\n }\n }\n\n const errorMessages: string[] = [];\n for (const includedReleaseTag of includedReleaseTags) {\n errorMessages.push(\n `${includedReleaseTag}: Release tags are always included in API reports and must not be specified`\n );\n }\n for (const [invalidTag, innerError] of invalidTags) {\n errorMessages.push(`${invalidTag}: ${innerError}`);\n }\n\n if (errorMessages.length > 0) {\n const errorMessage: string = [\n `\"tagsToReport\" contained one or more invalid tags:`,\n ...errorMessages\n ].join('\\n\\t- ');\n throw new Error(errorMessage);\n }\n}\n"]}
@@ -126,6 +126,40 @@ export interface IConfigApiReport {
126
126
  * @defaultValue `false`
127
127
  */
128
128
  includeForgottenExports?: boolean;
129
+ /**
130
+ * Specifies a list of {@link https://tsdoc.org/ | TSDoc} tags that should be reported in the API report file for
131
+ * items whose documentation contains them.
132
+ *
133
+ * @remarks
134
+ * Tag names must begin with `@`.
135
+ *
136
+ * This list may include standard TSDoc tags as well as custom ones.
137
+ * For more information on defining custom TSDoc tags, see
138
+ * {@link https://api-extractor.com/pages/configs/tsdoc_json/#defining-your-own-tsdoc-tags | here}.
139
+ *
140
+ * Note that an item's release tag will always reported; this behavior cannot be overridden.
141
+ *
142
+ * @defaultValue `@sealed`, `@virtual`, `@override`, `@eventProperty`, and `@deprecated`
143
+ *
144
+ * @example Omitting default tags
145
+ * To omit the `@sealed` and `@virtual` tags from API reports, you would specify `tagsToReport` as follows:
146
+ * ```json
147
+ * "tagsToReport": {
148
+ * "@sealed": false,
149
+ * "@virtual": false
150
+ * }
151
+ * ```
152
+ *
153
+ * @example Including additional tags
154
+ * To include additional tags to the set included in API reports, you could specify `tagsToReport` like this:
155
+ * ```json
156
+ * "tagsToReport": {
157
+ * "@customTag": true
158
+ * }
159
+ * ```
160
+ * This will result in `@customTag` being included in addition to the default tags.
161
+ */
162
+ tagsToReport?: Readonly<Record<`@${string}`, boolean>>;
129
163
  }
130
164
  /**
131
165
  * The allowed release tags that can be used to mark API items.
@@ -1 +1 @@
1
- {"version":3,"file":"IConfigFile.d.ts","sourceRoot":"","sources":["../../src/api/IConfigFile.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAC;AACtE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAE7D;;;;;;;GAOG;AACH,MAAM,WAAW,eAAe;IAC9B;;;;;;;;OAQG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAE1B;;;;;;;;;OASG;IACH,gBAAgB,CAAC,EAAE,EAAE,CAAC;IAEtB;;;;;;;;OAQG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB;AAED;;;;GAIG;AACH,MAAM,MAAM,gBAAgB,GAAG,QAAQ,GAAG,MAAM,GAAG,OAAO,GAAG,UAAU,CAAC;AAExE;;;;;;;GAOG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;OAEG;IACH,OAAO,EAAE,OAAO,CAAC;IAEjB;;;;;;;;;;;;;;;OAeG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB;;;;;;;;;;;;;OAaG;IACH,cAAc,CAAC,EAAE,gBAAgB,EAAE,CAAC;IAEpC;;;;;;;;;;OAUG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB;;;;;;;;;;OAUG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAE1B;;;;;;;;OAQG;IACH,uBAAuB,CAAC,EAAE,OAAO,CAAC;CACnC;AAED;;;GAGG;AACH,MAAM,MAAM,iBAAiB,GAAG,WAAW,GAAG,QAAQ,GAAG,OAAO,GAAG,SAAS,CAAC;AAE7E;;;;;;;GAOG;AACH,MAAM,WAAW,eAAe;IAC9B;;OAEG;IACH,OAAO,EAAE,OAAO,CAAC;IAEjB;;;;;;OAMG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB;;;;;;;;OAQG;IAC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EAAE,OAAO,CAAC;IAEnB;;;;;;;;OAQG;IACH,eAAe,CAAC,EAAE,eAAe,CAAC;IAElC;;OAEG;IACH,QAAQ,CAAC,EAAE,eAAe,CAAC;IAE3B;;OAEG;IACH,SAAS,CAAC,EAAE,gBAAgB,CAAC;IAE7B;;OAEG;IACH,QAAQ,CAAC,EAAE,eAAe,CAAC;IAE3B;;;OAGG;IACH,SAAS,CAAC,EAAE,gBAAgB,CAAC;IAE7B;;;OAGG;IACH,aAAa,CAAC,EAAE,oBAAoB,CAAC;IAErC;;OAEG;IACH,QAAQ,CAAC,EAAE,wBAAwB,CAAC;CACrC"}
@@ -1 +1 @@
1
- {"version":3,"file":"IConfigFile.js","sourceRoot":"","sources":["../../src/api/IConfigFile.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D","sourcesContent":["// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.\n// See LICENSE in the project root for license information.\n\nimport type { EnumMemberOrder } from '@microsoft/api-extractor-model';\nimport type { ExtractorLogLevel } from './ExtractorLogLevel';\n\n/**\n * Determines how the TypeScript compiler engine will be invoked by API Extractor.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigCompiler {\n /**\n * Specifies the path to the tsconfig.json file to be used by API Extractor when analyzing the project.\n *\n * @remarks\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n *\n * Note: This setting will be ignored if `overrideTsconfig` is used.\n */\n tsconfigFilePath?: string;\n\n /**\n * Provides a compiler configuration that will be used instead of reading the tsconfig.json file from disk.\n *\n * @remarks\n * The value must conform to the TypeScript tsconfig schema:\n *\n * http://json.schemastore.org/tsconfig\n *\n * If omitted, then the tsconfig.json file will instead be read from the projectFolder.\n */\n overrideTsconfig?: {};\n\n /**\n * This option causes the compiler to be invoked with the `--skipLibCheck` option.\n *\n * @remarks\n * This option is not recommended and may cause API Extractor to produce incomplete or incorrect declarations,\n * but it may be required when dependencies contain declarations that are incompatible with the TypeScript engine\n * that API Extractor uses for its analysis. Where possible, the underlying issue should be fixed rather than\n * relying on skipLibCheck.\n */\n skipLibCheck?: boolean;\n}\n\n/**\n * The allowed variations of API reports.\n *\n * @public\n */\nexport type ApiReportVariant = 'public' | 'beta' | 'alpha' | 'complete';\n\n/**\n * Configures how the API report files (*.api.md) will be generated.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigApiReport {\n /**\n * Whether to generate an API report.\n */\n enabled: boolean;\n\n /**\n * The base filename for the API report files, to be combined with {@link IConfigApiReport.reportFolder} or\n * {@link IConfigApiReport.reportTempFolder} to produce the full file path.\n *\n * @remarks\n * The `reportFileName` should not include any path separators such as `\\` or `/`. The `reportFileName` should\n * not include a file extension, since API Extractor will automatically append an appropriate file extension such\n * as `.api.md`. If the {@link IConfigApiReport.reportVariants} setting is used, then the file extension includes\n * the variant name, for example `my-report.public.api.md` or `my-report.beta.api.md`. The `complete` variant always\n * uses the simple extension `my-report.api.md`.\n *\n * Previous versions of API Extractor required `reportFileName` to include the `.api.md` extension explicitly;\n * for backwards compatibility, that is still accepted but will be discarded before applying the above rules.\n *\n * @defaultValue `<unscopedPackageName>`\n */\n reportFileName?: string;\n\n /**\n * The set of report variants to generate.\n *\n * @remarks\n * To support different approval requirements for different API levels, multiple \"variants\" of the API report can\n * be generated. The `reportVariants` setting specifies a list of variants to be generated. If omitted,\n * by default only the `complete` variant will be generated, which includes all `@internal`, `@alpha`, `@beta`,\n * and `@public` items. Other possible variants are `alpha` (`@alpha` + `@beta` + `@public`),\n * `beta` (`@beta` + `@public`), and `public` (`@public only`).\n *\n * The resulting API report file names will be derived from the {@link IConfigApiReport.reportFileName}.\n *\n * @defaultValue `[ \"complete\" ]`\n */\n reportVariants?: ApiReportVariant[];\n\n /**\n * Specifies the folder where the API report file is written. The file name portion is determined by\n * the `reportFileName` setting.\n *\n * @remarks\n * The API report file is normally tracked by Git. Changes to it can be used to trigger a branch policy,\n * e.g. for an API review.\n *\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n reportFolder?: string;\n\n /**\n * Specifies the folder where the temporary report file is written. The file name portion is determined by\n * the `reportFileName` setting.\n *\n * @remarks\n * After the temporary file is written to disk, it is compared with the file in the `reportFolder`.\n * If they are different, a production build will fail.\n *\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n reportTempFolder?: string;\n\n /**\n * Whether \"forgotten exports\" should be included in the API report file.\n *\n * @remarks\n * Forgotten exports are declarations flagged with `ae-forgotten-export` warnings. See\n * https://api-extractor.com/pages/messages/ae-forgotten-export/ to learn more.\n *\n * @defaultValue `false`\n */\n includeForgottenExports?: boolean;\n}\n\n/**\n * The allowed release tags that can be used to mark API items.\n * @public\n */\nexport type ReleaseTagForTrim = '@internal' | '@alpha' | '@beta' | '@public';\n\n/**\n * Configures how the doc model file (*.api.json) will be generated.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigDocModel {\n /**\n * Whether to generate a doc model file.\n */\n enabled: boolean;\n\n /**\n * The output path for the doc model file. The file extension should be \".api.json\".\n *\n * @remarks\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n apiJsonFilePath?: string;\n\n /**\n * Whether \"forgotten exports\" should be included in the doc model file.\n *\n * @remarks\n * Forgotten exports are declarations flagged with `ae-forgotten-export` warnings. See\n * https://api-extractor.com/pages/messages/ae-forgotten-export/ to learn more.\n *\n * @defaultValue `false`\n */\n includeForgottenExports?: boolean;\n\n /**\n * The base URL where the project's source code can be viewed on a website such as GitHub or\n * Azure DevOps. This URL path corresponds to the `<projectFolder>` path on disk.\n *\n * @remarks\n * This URL is concatenated with the file paths serialized to the doc model to produce URL file paths to individual API items.\n * For example, if the `projectFolderUrl` is \"https://github.com/microsoft/rushstack/tree/main/apps/api-extractor\" and an API\n * item's file path is \"api/ExtractorConfig.ts\", the full URL file path would be\n * \"https://github.com/microsoft/rushstack/tree/main/apps/api-extractor/api/ExtractorConfig.js\".\n *\n * Can be omitted if you don't need source code links in your API documentation reference.\n */\n projectFolderUrl?: string;\n\n /**\n * Specifies a list of release tags that will be trimmed from the doc model.\n *\n * @defaultValue `[\"@internal\"]`\n */\n releaseTagsToTrim?: ReleaseTagForTrim[];\n}\n\n/**\n * Configures how the .d.ts rollup file will be generated.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigDtsRollup {\n /**\n * Whether to generate the .d.ts rollup file.\n */\n enabled: boolean;\n\n /**\n * Specifies the output path for a .d.ts rollup file to be generated without any trimming.\n *\n * @remarks\n * This file will include all declarations that are exported by the main entry point.\n *\n * If the path is an empty string, then this file will not be written.\n *\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n untrimmedFilePath?: string;\n\n /**\n * Specifies the output path for a .d.ts rollup file to be generated with trimming for an \"alpha\" release.\n *\n * @remarks\n * This file will include only declarations that are marked as `@public`, `@beta`, or `@alpha`.\n *\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n alphaTrimmedFilePath?: string;\n\n /**\n * Specifies the output path for a .d.ts rollup file to be generated with trimming for a \"beta\" release.\n *\n * @remarks\n * This file will include only declarations that are marked as `@public` or `@beta`.\n *\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n betaTrimmedFilePath?: string;\n\n /**\n * Specifies the output path for a .d.ts rollup file to be generated with trimming for a \"public\" release.\n *\n * @remarks\n * This file will include only declarations that are marked as `@public`.\n *\n * If the path is an empty string, then this file will not be written.\n *\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n publicTrimmedFilePath?: string;\n\n /**\n * When a declaration is trimmed, by default it will be replaced by a code comment such as\n * \"Excluded from this release type: exampleMember\". Set \"omitTrimmingComments\" to true to remove the\n * declaration completely.\n */\n omitTrimmingComments?: boolean;\n}\n\n/**\n * Configures how the tsdoc-metadata.json file will be generated.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigTsdocMetadata {\n /**\n * Whether to generate the tsdoc-metadata.json file.\n */\n enabled: boolean;\n\n /**\n * Specifies where the TSDoc metadata file should be written.\n *\n * @remarks\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n *\n * The default value is `<lookup>`, which causes the path to be automatically inferred from the `tsdocMetadata`,\n * `typings` or `main` fields of the project's package.json. If none of these fields are set, the lookup\n * falls back to `tsdoc-metadata.json` in the package folder.\n */\n tsdocMetadataFilePath?: string;\n}\n\n/**\n * Configures reporting for a given message identifier.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigMessageReportingRule {\n /**\n * Specifies whether the message should be written to the the tool's output log.\n *\n * @remarks\n * Note that the `addToApiReportFile` property may supersede this option.\n */\n logLevel: ExtractorLogLevel;\n\n /**\n * When `addToApiReportFile` is true: If API Extractor is configured to write an API report file (.api.md),\n * then the message will be written inside that file; otherwise, the message is instead logged according to\n * the `logLevel` option.\n */\n addToApiReportFile?: boolean;\n}\n\n/**\n * Specifies a table of reporting rules for different message identifiers, and also the default rule used for\n * identifiers that do not appear in the table.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigMessageReportingTable {\n /**\n * The key is a message identifier for the associated type of message, or \"default\" to specify the default policy.\n * For example, the key might be `TS2551` (a compiler message), `tsdoc-link-tag-unescaped-text` (a TSDOc message),\n * or `ae-extra-release-tag` (a message related to the API Extractor analysis).\n */\n [messageId: string]: IConfigMessageReportingRule;\n}\n\n/**\n * Configures how API Extractor reports error and warning messages produced during analysis.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IExtractorMessagesConfig {\n /**\n * Configures handling of diagnostic messages generating the TypeScript compiler while analyzing the\n * input .d.ts files.\n */\n compilerMessageReporting?: IConfigMessageReportingTable;\n\n /**\n * Configures handling of messages reported by API Extractor during its analysis.\n */\n extractorMessageReporting?: IConfigMessageReportingTable;\n\n /**\n * Configures handling of messages reported by the TSDoc parser when analyzing code comments.\n */\n tsdocMessageReporting?: IConfigMessageReportingTable;\n}\n\n/**\n * Configuration options for the API Extractor tool. These options can be constructed programmatically\n * or loaded from the api-extractor.json config file using the {@link ExtractorConfig} class.\n *\n * @public\n */\nexport interface IConfigFile {\n /**\n * Optionally specifies another JSON config file that this file extends from. This provides a way for\n * standard settings to be shared across multiple projects.\n *\n * @remarks\n * If the path starts with `./` or `../`, the path is resolved relative to the folder of the file that contains\n * the `extends` field. Otherwise, the first path segment is interpreted as an NPM package name, and will be\n * resolved using NodeJS `require()`.\n */\n extends?: string;\n\n /**\n * Determines the `<projectFolder>` token that can be used with other config file settings. The project folder\n * typically contains the tsconfig.json and package.json config files, but the path is user-defined.\n *\n * @remarks\n *\n * The path is resolved relative to the folder of the config file that contains the setting.\n *\n * The default value for `projectFolder` is the token `<lookup>`, which means the folder is determined using\n * the following heuristics:\n *\n * If the config/rig.json system is used (as defined by {@link https://www.npmjs.com/package/@rushstack/rig-package\n * | @rushstack/rig-package}), then the `<lookup>` value will be the package folder that referenced the rig.\n *\n * Otherwise, the `<lookup>` value is determined by traversing parent folders, starting from the folder containing\n * api-extractor.json, and stopping at the first folder that contains a tsconfig.json file. If a tsconfig.json file\n * cannot be found in this way, then an error will be reported.\n */\n projectFolder?: string;\n\n /**\n * Specifies the .d.ts file to be used as the starting point for analysis. API Extractor\n * analyzes the symbols exported by this module.\n *\n * @remarks\n *\n * The file extension must be \".d.ts\" and not \".ts\".\n * The path is resolved relative to the \"projectFolder\" location.\n */\n mainEntryPointFilePath: string;\n\n /**\n * A list of NPM package names whose exports should be treated as part of this package.\n *\n * @remarks\n * Also supports glob patterns.\n * Note: glob patterns will **only** be resolved against dependencies listed in the project's package.json file.\n *\n * * This is both a safety and a performance precaution.\n *\n * Exact package names will be applied against any dependency encountered while walking the type graph, regardless of\n * dependencies listed in the package.json.\n *\n * @example\n *\n * Suppose that Webpack is used to generate a distributed bundle for the project `library1`,\n * and another NPM package `library2` is embedded in this bundle. Some types from `library2` may become part\n * of the exported API for `library1`, but by default API Extractor would generate a .d.ts rollup that explicitly\n * imports `library2`. To avoid this, we can specify:\n *\n * ```js\n * \"bundledPackages\": [ \"library2\" ],\n * ```\n *\n * This would direct API Extractor to embed those types directly in the .d.ts rollup, as if they had been\n * local files for `library1`.\n */\n bundledPackages?: string[];\n\n /**\n * Specifies what type of newlines API Extractor should use when writing output files.\n *\n * @remarks\n * By default, the output files will be written with Windows-style newlines.\n * To use POSIX-style newlines, specify \"lf\" instead.\n * To use the OS's default newline kind, specify \"os\".\n */\n newlineKind?: 'crlf' | 'lf' | 'os';\n\n /**\n * Set to true when invoking API Extractor's test harness.\n * @remarks\n * When `testMode` is true, the `toolVersion` field in the .api.json file is assigned an empty string\n * to prevent spurious diffs in output files tracked for tests.\n */\n testMode?: boolean;\n\n /**\n * Specifies how API Extractor sorts members of an enum when generating the .api.json file.\n *\n * @remarks\n * By default, the output files will be sorted alphabetically, which is \"by-name\".\n * To keep the ordering in the source code, specify \"preserve\".\n *\n * @defaultValue `by-name`\n */\n enumMemberOrder?: EnumMemberOrder;\n\n /**\n * {@inheritDoc IConfigCompiler}\n */\n compiler?: IConfigCompiler;\n\n /**\n * {@inheritDoc IConfigApiReport}\n */\n apiReport?: IConfigApiReport;\n\n /**\n * {@inheritDoc IConfigDocModel}\n */\n docModel?: IConfigDocModel;\n\n /**\n * {@inheritDoc IConfigDtsRollup}\n * @beta\n */\n dtsRollup?: IConfigDtsRollup;\n\n /**\n * {@inheritDoc IConfigTsdocMetadata}\n * @beta\n */\n tsdocMetadata?: IConfigTsdocMetadata;\n\n /**\n * {@inheritDoc IExtractorMessagesConfig}\n */\n messages?: IExtractorMessagesConfig;\n}\n"]}
1
+ {"version":3,"file":"IConfigFile.js","sourceRoot":"","sources":["../../src/api/IConfigFile.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D","sourcesContent":["// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.\n// See LICENSE in the project root for license information.\n\nimport type { EnumMemberOrder } from '@microsoft/api-extractor-model';\nimport type { ExtractorLogLevel } from './ExtractorLogLevel';\n\n/**\n * Determines how the TypeScript compiler engine will be invoked by API Extractor.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigCompiler {\n /**\n * Specifies the path to the tsconfig.json file to be used by API Extractor when analyzing the project.\n *\n * @remarks\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n *\n * Note: This setting will be ignored if `overrideTsconfig` is used.\n */\n tsconfigFilePath?: string;\n\n /**\n * Provides a compiler configuration that will be used instead of reading the tsconfig.json file from disk.\n *\n * @remarks\n * The value must conform to the TypeScript tsconfig schema:\n *\n * http://json.schemastore.org/tsconfig\n *\n * If omitted, then the tsconfig.json file will instead be read from the projectFolder.\n */\n overrideTsconfig?: {};\n\n /**\n * This option causes the compiler to be invoked with the `--skipLibCheck` option.\n *\n * @remarks\n * This option is not recommended and may cause API Extractor to produce incomplete or incorrect declarations,\n * but it may be required when dependencies contain declarations that are incompatible with the TypeScript engine\n * that API Extractor uses for its analysis. Where possible, the underlying issue should be fixed rather than\n * relying on skipLibCheck.\n */\n skipLibCheck?: boolean;\n}\n\n/**\n * The allowed variations of API reports.\n *\n * @public\n */\nexport type ApiReportVariant = 'public' | 'beta' | 'alpha' | 'complete';\n\n/**\n * Configures how the API report files (*.api.md) will be generated.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigApiReport {\n /**\n * Whether to generate an API report.\n */\n enabled: boolean;\n\n /**\n * The base filename for the API report files, to be combined with {@link IConfigApiReport.reportFolder} or\n * {@link IConfigApiReport.reportTempFolder} to produce the full file path.\n *\n * @remarks\n * The `reportFileName` should not include any path separators such as `\\` or `/`. The `reportFileName` should\n * not include a file extension, since API Extractor will automatically append an appropriate file extension such\n * as `.api.md`. If the {@link IConfigApiReport.reportVariants} setting is used, then the file extension includes\n * the variant name, for example `my-report.public.api.md` or `my-report.beta.api.md`. The `complete` variant always\n * uses the simple extension `my-report.api.md`.\n *\n * Previous versions of API Extractor required `reportFileName` to include the `.api.md` extension explicitly;\n * for backwards compatibility, that is still accepted but will be discarded before applying the above rules.\n *\n * @defaultValue `<unscopedPackageName>`\n */\n reportFileName?: string;\n\n /**\n * The set of report variants to generate.\n *\n * @remarks\n * To support different approval requirements for different API levels, multiple \"variants\" of the API report can\n * be generated. The `reportVariants` setting specifies a list of variants to be generated. If omitted,\n * by default only the `complete` variant will be generated, which includes all `@internal`, `@alpha`, `@beta`,\n * and `@public` items. Other possible variants are `alpha` (`@alpha` + `@beta` + `@public`),\n * `beta` (`@beta` + `@public`), and `public` (`@public only`).\n *\n * The resulting API report file names will be derived from the {@link IConfigApiReport.reportFileName}.\n *\n * @defaultValue `[ \"complete\" ]`\n */\n reportVariants?: ApiReportVariant[];\n\n /**\n * Specifies the folder where the API report file is written. The file name portion is determined by\n * the `reportFileName` setting.\n *\n * @remarks\n * The API report file is normally tracked by Git. Changes to it can be used to trigger a branch policy,\n * e.g. for an API review.\n *\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n reportFolder?: string;\n\n /**\n * Specifies the folder where the temporary report file is written. The file name portion is determined by\n * the `reportFileName` setting.\n *\n * @remarks\n * After the temporary file is written to disk, it is compared with the file in the `reportFolder`.\n * If they are different, a production build will fail.\n *\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n reportTempFolder?: string;\n\n /**\n * Whether \"forgotten exports\" should be included in the API report file.\n *\n * @remarks\n * Forgotten exports are declarations flagged with `ae-forgotten-export` warnings. See\n * https://api-extractor.com/pages/messages/ae-forgotten-export/ to learn more.\n *\n * @defaultValue `false`\n */\n includeForgottenExports?: boolean;\n\n /**\n * Specifies a list of {@link https://tsdoc.org/ | TSDoc} tags that should be reported in the API report file for\n * items whose documentation contains them.\n *\n * @remarks\n * Tag names must begin with `@`.\n *\n * This list may include standard TSDoc tags as well as custom ones.\n * For more information on defining custom TSDoc tags, see\n * {@link https://api-extractor.com/pages/configs/tsdoc_json/#defining-your-own-tsdoc-tags | here}.\n *\n * Note that an item's release tag will always reported; this behavior cannot be overridden.\n *\n * @defaultValue `@sealed`, `@virtual`, `@override`, `@eventProperty`, and `@deprecated`\n *\n * @example Omitting default tags\n * To omit the `@sealed` and `@virtual` tags from API reports, you would specify `tagsToReport` as follows:\n * ```json\n * \"tagsToReport\": {\n * \"@sealed\": false,\n * \"@virtual\": false\n * }\n * ```\n *\n * @example Including additional tags\n * To include additional tags to the set included in API reports, you could specify `tagsToReport` like this:\n * ```json\n * \"tagsToReport\": {\n * \"@customTag\": true\n * }\n * ```\n * This will result in `@customTag` being included in addition to the default tags.\n */\n tagsToReport?: Readonly<Record<`@${string}`, boolean>>;\n}\n\n/**\n * The allowed release tags that can be used to mark API items.\n * @public\n */\nexport type ReleaseTagForTrim = '@internal' | '@alpha' | '@beta' | '@public';\n\n/**\n * Configures how the doc model file (*.api.json) will be generated.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigDocModel {\n /**\n * Whether to generate a doc model file.\n */\n enabled: boolean;\n\n /**\n * The output path for the doc model file. The file extension should be \".api.json\".\n *\n * @remarks\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n apiJsonFilePath?: string;\n\n /**\n * Whether \"forgotten exports\" should be included in the doc model file.\n *\n * @remarks\n * Forgotten exports are declarations flagged with `ae-forgotten-export` warnings. See\n * https://api-extractor.com/pages/messages/ae-forgotten-export/ to learn more.\n *\n * @defaultValue `false`\n */\n includeForgottenExports?: boolean;\n\n /**\n * The base URL where the project's source code can be viewed on a website such as GitHub or\n * Azure DevOps. This URL path corresponds to the `<projectFolder>` path on disk.\n *\n * @remarks\n * This URL is concatenated with the file paths serialized to the doc model to produce URL file paths to individual API items.\n * For example, if the `projectFolderUrl` is \"https://github.com/microsoft/rushstack/tree/main/apps/api-extractor\" and an API\n * item's file path is \"api/ExtractorConfig.ts\", the full URL file path would be\n * \"https://github.com/microsoft/rushstack/tree/main/apps/api-extractor/api/ExtractorConfig.js\".\n *\n * Can be omitted if you don't need source code links in your API documentation reference.\n */\n projectFolderUrl?: string;\n\n /**\n * Specifies a list of release tags that will be trimmed from the doc model.\n *\n * @defaultValue `[\"@internal\"]`\n */\n releaseTagsToTrim?: ReleaseTagForTrim[];\n}\n\n/**\n * Configures how the .d.ts rollup file will be generated.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigDtsRollup {\n /**\n * Whether to generate the .d.ts rollup file.\n */\n enabled: boolean;\n\n /**\n * Specifies the output path for a .d.ts rollup file to be generated without any trimming.\n *\n * @remarks\n * This file will include all declarations that are exported by the main entry point.\n *\n * If the path is an empty string, then this file will not be written.\n *\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n untrimmedFilePath?: string;\n\n /**\n * Specifies the output path for a .d.ts rollup file to be generated with trimming for an \"alpha\" release.\n *\n * @remarks\n * This file will include only declarations that are marked as `@public`, `@beta`, or `@alpha`.\n *\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n alphaTrimmedFilePath?: string;\n\n /**\n * Specifies the output path for a .d.ts rollup file to be generated with trimming for a \"beta\" release.\n *\n * @remarks\n * This file will include only declarations that are marked as `@public` or `@beta`.\n *\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n betaTrimmedFilePath?: string;\n\n /**\n * Specifies the output path for a .d.ts rollup file to be generated with trimming for a \"public\" release.\n *\n * @remarks\n * This file will include only declarations that are marked as `@public`.\n *\n * If the path is an empty string, then this file will not be written.\n *\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n */\n publicTrimmedFilePath?: string;\n\n /**\n * When a declaration is trimmed, by default it will be replaced by a code comment such as\n * \"Excluded from this release type: exampleMember\". Set \"omitTrimmingComments\" to true to remove the\n * declaration completely.\n */\n omitTrimmingComments?: boolean;\n}\n\n/**\n * Configures how the tsdoc-metadata.json file will be generated.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigTsdocMetadata {\n /**\n * Whether to generate the tsdoc-metadata.json file.\n */\n enabled: boolean;\n\n /**\n * Specifies where the TSDoc metadata file should be written.\n *\n * @remarks\n * The path is resolved relative to the folder of the config file that contains the setting; to change this,\n * prepend a folder token such as `<projectFolder>`.\n *\n * The default value is `<lookup>`, which causes the path to be automatically inferred from the `tsdocMetadata`,\n * `typings` or `main` fields of the project's package.json. If none of these fields are set, the lookup\n * falls back to `tsdoc-metadata.json` in the package folder.\n */\n tsdocMetadataFilePath?: string;\n}\n\n/**\n * Configures reporting for a given message identifier.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigMessageReportingRule {\n /**\n * Specifies whether the message should be written to the the tool's output log.\n *\n * @remarks\n * Note that the `addToApiReportFile` property may supersede this option.\n */\n logLevel: ExtractorLogLevel;\n\n /**\n * When `addToApiReportFile` is true: If API Extractor is configured to write an API report file (.api.md),\n * then the message will be written inside that file; otherwise, the message is instead logged according to\n * the `logLevel` option.\n */\n addToApiReportFile?: boolean;\n}\n\n/**\n * Specifies a table of reporting rules for different message identifiers, and also the default rule used for\n * identifiers that do not appear in the table.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IConfigMessageReportingTable {\n /**\n * The key is a message identifier for the associated type of message, or \"default\" to specify the default policy.\n * For example, the key might be `TS2551` (a compiler message), `tsdoc-link-tag-unescaped-text` (a TSDOc message),\n * or `ae-extra-release-tag` (a message related to the API Extractor analysis).\n */\n [messageId: string]: IConfigMessageReportingRule;\n}\n\n/**\n * Configures how API Extractor reports error and warning messages produced during analysis.\n *\n * @remarks\n * This is part of the {@link IConfigFile} structure.\n *\n * @public\n */\nexport interface IExtractorMessagesConfig {\n /**\n * Configures handling of diagnostic messages generating the TypeScript compiler while analyzing the\n * input .d.ts files.\n */\n compilerMessageReporting?: IConfigMessageReportingTable;\n\n /**\n * Configures handling of messages reported by API Extractor during its analysis.\n */\n extractorMessageReporting?: IConfigMessageReportingTable;\n\n /**\n * Configures handling of messages reported by the TSDoc parser when analyzing code comments.\n */\n tsdocMessageReporting?: IConfigMessageReportingTable;\n}\n\n/**\n * Configuration options for the API Extractor tool. These options can be constructed programmatically\n * or loaded from the api-extractor.json config file using the {@link ExtractorConfig} class.\n *\n * @public\n */\nexport interface IConfigFile {\n /**\n * Optionally specifies another JSON config file that this file extends from. This provides a way for\n * standard settings to be shared across multiple projects.\n *\n * @remarks\n * If the path starts with `./` or `../`, the path is resolved relative to the folder of the file that contains\n * the `extends` field. Otherwise, the first path segment is interpreted as an NPM package name, and will be\n * resolved using NodeJS `require()`.\n */\n extends?: string;\n\n /**\n * Determines the `<projectFolder>` token that can be used with other config file settings. The project folder\n * typically contains the tsconfig.json and package.json config files, but the path is user-defined.\n *\n * @remarks\n *\n * The path is resolved relative to the folder of the config file that contains the setting.\n *\n * The default value for `projectFolder` is the token `<lookup>`, which means the folder is determined using\n * the following heuristics:\n *\n * If the config/rig.json system is used (as defined by {@link https://www.npmjs.com/package/@rushstack/rig-package\n * | @rushstack/rig-package}), then the `<lookup>` value will be the package folder that referenced the rig.\n *\n * Otherwise, the `<lookup>` value is determined by traversing parent folders, starting from the folder containing\n * api-extractor.json, and stopping at the first folder that contains a tsconfig.json file. If a tsconfig.json file\n * cannot be found in this way, then an error will be reported.\n */\n projectFolder?: string;\n\n /**\n * Specifies the .d.ts file to be used as the starting point for analysis. API Extractor\n * analyzes the symbols exported by this module.\n *\n * @remarks\n *\n * The file extension must be \".d.ts\" and not \".ts\".\n * The path is resolved relative to the \"projectFolder\" location.\n */\n mainEntryPointFilePath: string;\n\n /**\n * A list of NPM package names whose exports should be treated as part of this package.\n *\n * @remarks\n * Also supports glob patterns.\n * Note: glob patterns will **only** be resolved against dependencies listed in the project's package.json file.\n *\n * * This is both a safety and a performance precaution.\n *\n * Exact package names will be applied against any dependency encountered while walking the type graph, regardless of\n * dependencies listed in the package.json.\n *\n * @example\n *\n * Suppose that Webpack is used to generate a distributed bundle for the project `library1`,\n * and another NPM package `library2` is embedded in this bundle. Some types from `library2` may become part\n * of the exported API for `library1`, but by default API Extractor would generate a .d.ts rollup that explicitly\n * imports `library2`. To avoid this, we can specify:\n *\n * ```js\n * \"bundledPackages\": [ \"library2\" ],\n * ```\n *\n * This would direct API Extractor to embed those types directly in the .d.ts rollup, as if they had been\n * local files for `library1`.\n */\n bundledPackages?: string[];\n\n /**\n * Specifies what type of newlines API Extractor should use when writing output files.\n *\n * @remarks\n * By default, the output files will be written with Windows-style newlines.\n * To use POSIX-style newlines, specify \"lf\" instead.\n * To use the OS's default newline kind, specify \"os\".\n */\n newlineKind?: 'crlf' | 'lf' | 'os';\n\n /**\n * Set to true when invoking API Extractor's test harness.\n * @remarks\n * When `testMode` is true, the `toolVersion` field in the .api.json file is assigned an empty string\n * to prevent spurious diffs in output files tracked for tests.\n */\n testMode?: boolean;\n\n /**\n * Specifies how API Extractor sorts members of an enum when generating the .api.json file.\n *\n * @remarks\n * By default, the output files will be sorted alphabetically, which is \"by-name\".\n * To keep the ordering in the source code, specify \"preserve\".\n *\n * @defaultValue `by-name`\n */\n enumMemberOrder?: EnumMemberOrder;\n\n /**\n * {@inheritDoc IConfigCompiler}\n */\n compiler?: IConfigCompiler;\n\n /**\n * {@inheritDoc IConfigApiReport}\n */\n apiReport?: IConfigApiReport;\n\n /**\n * {@inheritDoc IConfigDocModel}\n */\n docModel?: IConfigDocModel;\n\n /**\n * {@inheritDoc IConfigDtsRollup}\n * @beta\n */\n dtsRollup?: IConfigDtsRollup;\n\n /**\n * {@inheritDoc IConfigTsdocMetadata}\n * @beta\n */\n tsdocMetadata?: IConfigTsdocMetadata;\n\n /**\n * {@inheritDoc IExtractorMessagesConfig}\n */\n messages?: IExtractorMessagesConfig;\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"ApiReportGenerator.d.ts","sourceRoot":"","sources":["../../src/generators/ApiReportGenerator.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAgBnD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAE3D,qBAAa,kBAAkB;IAC7B,OAAO,CAAC,MAAM,CAAC,iBAAiB,CAAmB;IAEnD;;;;;;OAMG;WACW,4BAA4B,CACxC,iBAAiB,EAAE,MAAM,EACzB,mBAAmB,EAAE,MAAM,GAC1B,OAAO;IAOV;;;;;OAKG;WACW,yBAAyB,CAAC,SAAS,EAAE,SAAS,EAAE,aAAa,EAAE,gBAAgB,GAAG,MAAM;IAsNtG;;OAEG;IACH,OAAO,CAAC,MAAM,CAAC,WAAW;IA8L1B,OAAO,CAAC,MAAM,CAAC,sBAAsB;IAkCrC;;OAEG;IACH,OAAO,CAAC,MAAM,CAAC,yBAAyB;IA8CxC;;;;OAIG;IACH,OAAO,CAAC,MAAM,CAAC,iBAAiB;IAgEhC,OAAO,CAAC,MAAM,CAAC,oBAAoB;CAQpC"}
1
+ {"version":3,"file":"ApiReportGenerator.d.ts","sourceRoot":"","sources":["../../src/generators/ApiReportGenerator.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAgBnD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAE3D,qBAAa,kBAAkB;IAC7B,OAAO,CAAC,MAAM,CAAC,iBAAiB,CAAmB;IAEnD;;;;;;OAMG;WACW,4BAA4B,CACxC,iBAAiB,EAAE,MAAM,EACzB,mBAAmB,EAAE,MAAM,GAC1B,OAAO;IAOV;;;;;OAKG;WACW,yBAAyB,CAAC,SAAS,EAAE,SAAS,EAAE,aAAa,EAAE,gBAAgB,GAAG,MAAM;IAsNtG;;OAEG;IACH,OAAO,CAAC,MAAM,CAAC,WAAW;IA8L1B,OAAO,CAAC,MAAM,CAAC,sBAAsB;IAkCrC;;OAEG;IACH,OAAO,CAAC,MAAM,CAAC,yBAAyB;IA8CxC;;;;OAIG;IACH,OAAO,CAAC,MAAM,CAAC,iBAAiB;IAuFhC,OAAO,CAAC,MAAM,CAAC,oBAAoB;CAQpC"}
@@ -34,6 +34,17 @@ var __importStar = (this && this.__importStar) || (function () {
34
34
  return result;
35
35
  };
36
36
  })();
37
+ var __rest = (this && this.__rest) || function (s, e) {
38
+ var t = {};
39
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
40
+ t[p] = s[p];
41
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
42
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
43
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
44
+ t[p[i]] = s[p[i]];
45
+ }
46
+ return t;
47
+ };
37
48
  Object.defineProperty(exports, "__esModule", { value: true });
38
49
  exports.ApiReportGenerator = void 0;
39
50
  const ts = __importStar(require("typescript"));
@@ -443,6 +454,7 @@ class ApiReportGenerator {
443
454
  * by the analysis.
444
455
  */
445
456
  static _getAedocSynopsis(collector, astDeclaration, messagesToReport) {
457
+ var _a, _b, _c;
446
458
  const writer = new IndentedWriter_1.IndentedWriter();
447
459
  for (const message of messagesToReport) {
448
460
  ApiReportGenerator._writeLineAsComments(writer, 'Warning: ' + message.formatMessageWithoutLocation());
@@ -450,28 +462,46 @@ class ApiReportGenerator {
450
462
  if (!collector.isAncillaryDeclaration(astDeclaration)) {
451
463
  const footerParts = [];
452
464
  const apiItemMetadata = collector.fetchApiItemMetadata(astDeclaration);
465
+ // 1. Release tag (if present)
453
466
  if (!apiItemMetadata.releaseTagSameAsParent) {
454
467
  if (apiItemMetadata.effectiveReleaseTag !== api_extractor_model_1.ReleaseTag.None) {
455
468
  footerParts.push(api_extractor_model_1.ReleaseTag.getTagName(apiItemMetadata.effectiveReleaseTag));
456
469
  }
457
470
  }
458
- if (apiItemMetadata.isSealed) {
471
+ // 2. Enumerate configured tags, reporting standard system tags first and then other configured tags.
472
+ // Note that the ordering we handle the standard tags is important for backwards compatibility.
473
+ // Also note that we had special mechanisms for checking whether or not an item is documented with these tags,
474
+ // so they are checked specially.
475
+ const _d = collector.extractorConfig.tagsToReport, { '@sealed': reportSealedTag, '@virtual': reportVirtualTag, '@override': reportOverrideTag, '@eventProperty': reportEventPropertyTag, '@deprecated': reportDeprecatedTag } = _d, otherTagsToReport = __rest(_d, ['@sealed', '@virtual', '@override', '@eventProperty', '@deprecated']);
476
+ // 2.a Check for standard tags and report those that are both configured and present in the metadata.
477
+ if (reportSealedTag && apiItemMetadata.isSealed) {
459
478
  footerParts.push('@sealed');
460
479
  }
461
- if (apiItemMetadata.isVirtual) {
480
+ if (reportVirtualTag && apiItemMetadata.isVirtual) {
462
481
  footerParts.push('@virtual');
463
482
  }
464
- if (apiItemMetadata.isOverride) {
483
+ if (reportOverrideTag && apiItemMetadata.isOverride) {
465
484
  footerParts.push('@override');
466
485
  }
467
- if (apiItemMetadata.isEventProperty) {
486
+ if (reportEventPropertyTag && apiItemMetadata.isEventProperty) {
468
487
  footerParts.push('@eventProperty');
469
488
  }
470
- if (apiItemMetadata.tsdocComment) {
471
- if (apiItemMetadata.tsdocComment.deprecatedBlock) {
472
- footerParts.push('@deprecated');
489
+ if (reportDeprecatedTag && ((_a = apiItemMetadata.tsdocComment) === null || _a === void 0 ? void 0 : _a.deprecatedBlock)) {
490
+ footerParts.push('@deprecated');
491
+ }
492
+ // 2.b Check for other configured tags and report those that are present in the tsdoc metadata.
493
+ for (const [tag, reportTag] of Object.entries(otherTagsToReport)) {
494
+ if (reportTag) {
495
+ // If the tag was not handled specially, check if it is present in the metadata.
496
+ if ((_b = apiItemMetadata.tsdocComment) === null || _b === void 0 ? void 0 : _b.customBlocks.some((block) => block.blockTag.tagName === tag)) {
497
+ footerParts.push(tag);
498
+ }
499
+ else if ((_c = apiItemMetadata.tsdocComment) === null || _c === void 0 ? void 0 : _c.modifierTagSet.hasTagName(tag)) {
500
+ footerParts.push(tag);
501
+ }
473
502
  }
474
503
  }
504
+ // 3. If the item is undocumented, append notice at the end of the list
475
505
  if (apiItemMetadata.undocumented) {
476
506
  footerParts.push('(undocumented)');
477
507
  collector.messageRouter.addAnalyzerIssue(ExtractorMessageId_1.ExtractorMessageId.Undocumented, `Missing documentation for "${astDeclaration.astSymbol.localName}".`, astDeclaration);
@@ -1 +1 @@
1
- {"version":3,"file":"ApiReportGenerator.js","sourceRoot":"","sources":["../../src/generators/ApiReportGenerator.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAE3D,+CAAiC;AACjC,oEAAmE;AACnE,wEAA4D;AAE5D,sDAAmD;AACnD,qEAAkE;AAClE,2CAAwC;AAExC,+DAA4D;AAE5D,qDAAkD;AAClD,qDAAkD;AAElD,qDAAkD;AAClD,qDAAkD;AAClD,uEAAoE;AAGpE,yFAAsF;AACtF,kEAA+D;AAG/D,MAAa,kBAAkB;IAG7B;;;;;;OAMG;IACI,MAAM,CAAC,4BAA4B,CACxC,iBAAyB,EACzB,mBAA2B;QAE3B,wCAAwC;QACxC,MAAM,g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CAAC;YACzE,CAAC;QACH,CAAC;QAED,OAAO,MAAM,CAAC,QAAQ,EAAE,CAAC;IAC3B,CAAC;IAEO,MAAM,CAAC,oBAAoB,CAAC,MAAsB,EAAE,IAAY;QACtE,MAAM,KAAK,GAAa,wBAAI,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;QAC3D,KAAK,MAAM,QAAQ,IAAI,KAAK,EAAE,CAAC;YAC7B,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;YACpB,MAAM,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC;YACvB,MAAM,CAAC,SAAS,EAAE,CAAC;QACrB,CAAC;IACH,CAAC;;AAhlBH,gDAilBC;AAhlBgB,oCAAiB,GAAW,OAAO,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.\n// See LICENSE in the project root for license information.\n\nimport * as ts from 'typescript';\nimport { Text, InternalError } from '@rushstack/node-core-library';\nimport { ReleaseTag } from '@microsoft/api-extractor-model';\n\nimport { Collector } from '../collector/Collector';\nimport { TypeScriptHelpers } from '../analyzer/TypeScriptHelpers';\nimport { Span } from '../analyzer/Span';\nimport type { CollectorEntity } from '../collector/CollectorEntity';\nimport { AstDeclaration } from '../analyzer/AstDeclaration';\nimport type { ApiItemMetadata } from '../collector/ApiItemMetadata';\nimport { AstImport } from '../analyzer/AstImport';\nimport { AstSymbol } from '../analyzer/AstSymbol';\nimport type { ExtractorMessage } from '../api/ExtractorMessage';\nimport { IndentedWriter } from './IndentedWriter';\nimport { DtsEmitHelpers } from './DtsEmitHelpers';\nimport { AstNamespaceImport } from '../analyzer/AstNamespaceImport';\nimport type { AstEntity } from '../analyzer/AstEntity';\nimport type { IAstModuleExportInfo } from '../analyzer/AstModule';\nimport { SourceFileLocationFormatter } from '../analyzer/SourceFileLocationFormatter';\nimport { ExtractorMessageId } from '../api/ExtractorMessageId';\nimport type { ApiReportVariant } from '../api/IConfigFile';\n\nexport class ApiReportGenerator {\n private static _trimSpacesRegExp: RegExp = / +$/gm;\n\n /**\n * Compares the contents of two API files that were created using ApiFileGenerator,\n * and returns true if they are equivalent. Note that these files are not normally edited\n * by a human; the \"equivalence\" comparison here is intended to ignore spurious changes that\n * might be introduced by a tool, e.g. Git newline normalization or an editor that strips\n * whitespace when saving.\n */\n public static areEquivalentApiFileContents(\n actualFileContent: string,\n expectedFileContent: string\n ): boolean {\n // NOTE: \"\\s\" also matches \"\\r\" and \"\\n\"\n const normalizedActual: string = actualFileContent.replace(/[\\s]+/g, ' ');\n const normalizedExpected: string = expectedFileContent.replace(/[\\s]+/g, ' ');\n return normalizedActual === normalizedExpected;\n }\n\n /**\n * Generates and returns the API report contents as a string.\n *\n * @param reportVariant - The release level with which the report is associated.\n * Can also be viewed as the minimal release level of items that should be included in the report.\n */\n public static generateReviewFileContent(collector: Collector, reportVariant: ApiReportVariant): string {\n const writer: IndentedWriter = new IndentedWriter();\n writer.trimLeadingSpaces = true;\n\n function capitalizeFirstLetter(input: string): string {\n return input === '' ? '' : `${input[0].toLocaleUpperCase()}${input.slice(1)}`;\n }\n\n // For backwards compatibility, don't emit \"complete\" in report text for untrimmed reports.\n const releaseLevelPrefix: string =\n reportVariant === 'complete' ? '' : `${capitalizeFirstLetter(reportVariant)} `;\n writer.writeLine(\n [\n `## ${releaseLevelPrefix}API Report File for \"${collector.workingPackage.name}\"`,\n ``,\n `> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).`,\n ``\n ].join('\\n')\n );\n\n // Write the opening delimiter for the Markdown code fence\n writer.writeLine('```ts\\n');\n\n // Emit the triple slash directives\n for (const typeDirectiveReference of Array.from(collector.dtsTypeReferenceDirectives).sort()) {\n // https://github.com/microsoft/TypeScript/blob/611ebc7aadd7a44a4c0447698bfda9222a78cb66/src/compiler/declarationEmitter.ts#L162\n writer.writeLine(`/// <reference types=\"${typeDirectiveReference}\" />`);\n }\n for (const libDirectiveReference of Array.from(collector.dtsLibReferenceDirectives).sort()) {\n writer.writeLine(`/// <reference lib=\"${libDirectiveReference}\" />`);\n }\n writer.ensureSkippedLine();\n\n // Emit the imports\n for (const entity of collector.entities) {\n if (entity.astEntity instanceof AstImport) {\n DtsEmitHelpers.emitImport(writer, entity, entity.astEntity);\n }\n }\n writer.ensureSkippedLine();\n\n // Emit the regular declarations\n for (const entity of collector.entities) {\n const astEntity: AstEntity = entity.astEntity;\n if (entity.consumable || collector.extractorConfig.apiReportIncludeForgottenExports) {\n // First, collect the list of export names for this symbol. When reporting messages with\n // ExtractorMessage.properties.exportName, this will enable us to emit the warning comments alongside\n // the associated export statement.\n interface IExportToEmit {\n readonly exportName: string;\n readonly associatedMessages: ExtractorMessage[];\n }\n const exportsToEmit: Map<string, IExportToEmit> = new Map<string, IExportToEmit>();\n\n for (const exportName of entity.exportNames) {\n if (!entity.shouldInlineExport) {\n exportsToEmit.set(exportName, { exportName, associatedMessages: [] });\n }\n }\n\n if (astEntity instanceof AstSymbol) {\n // Emit all the declarations for this entity\n for (const astDeclaration of astEntity.astDeclarations || []) {\n // Get the messages associated with this declaration\n const fetchedMessages: ExtractorMessage[] =\n collector.messageRouter.fetchAssociatedMessagesForReviewFile(astDeclaration);\n\n // Peel off the messages associated with an export statement and store them\n // in IExportToEmit.associatedMessages (to be processed later). The remaining messages will\n // added to messagesToReport, to be emitted next to the declaration instead of the export statement.\n const messagesToReport: ExtractorMessage[] = [];\n for (const message of fetchedMessages) {\n if (message.properties.exportName) {\n const exportToEmit: IExportToEmit | undefined = exportsToEmit.get(\n message.properties.exportName\n );\n if (exportToEmit) {\n exportToEmit.associatedMessages.push(message);\n continue;\n }\n }\n messagesToReport.push(message);\n }\n\n if (this._shouldIncludeInReport(collector, astDeclaration, reportVariant)) {\n writer.ensureSkippedLine();\n writer.write(ApiReportGenerator._getAedocSynopsis(collector, astDeclaration, messagesToReport));\n\n const span: Span = new Span(astDeclaration.declaration);\n\n const apiItemMetadata: ApiItemMetadata = collector.fetchApiItemMetadata(astDeclaration);\n if (apiItemMetadata.isPreapproved) {\n ApiReportGenerator._modifySpanForPreapproved(span);\n } else {\n ApiReportGenerator._modifySpan(collector, span, entity, astDeclaration, false, reportVariant);\n }\n\n span.writeModifiedText(writer);\n writer.ensureNewLine();\n }\n }\n }\n\n if (astEntity instanceof AstNamespaceImport) {\n const astModuleExportInfo: IAstModuleExportInfo = astEntity.fetchAstModuleExportInfo(collector);\n\n if (entity.nameForEmit === undefined) {\n // This should never happen\n throw new InternalError('referencedEntry.nameForEmit is undefined');\n }\n\n if (astModuleExportInfo.starExportedExternalModules.size > 0) {\n // We could support this, but we would need to find a way to safely represent it.\n throw new Error(\n `The ${entity.nameForEmit} namespace import includes a star export, which is not supported:\\n` +\n SourceFileLocationFormatter.formatDeclaration(astEntity.declaration)\n );\n }\n\n // Emit a synthetic declaration for the namespace. It will look like this:\n //\n // declare namespace example {\n // export {\n // f1,\n // f2\n // }\n // }\n //\n // Note that we do not try to relocate f1()/f2() to be inside the namespace because other type\n // signatures may reference them directly (without using the namespace qualifier).\n\n writer.ensureSkippedLine();\n writer.writeLine(`declare namespace ${entity.nameForEmit} {`);\n\n // all local exports of local imported module are just references to top-level declarations\n writer.increaseIndent();\n writer.writeLine('export {');\n writer.increaseIndent();\n\n const exportClauses: string[] = [];\n for (const [exportedName, exportedEntity] of astModuleExportInfo.exportedLocalEntities) {\n const collectorEntity: CollectorEntity | undefined =\n collector.tryGetCollectorEntity(exportedEntity);\n if (collectorEntity === undefined) {\n // This should never happen\n // top-level exports of local imported module should be added as collector entities before\n throw new InternalError(\n `Cannot find collector entity for ${entity.nameForEmit}.${exportedEntity.localName}`\n );\n }\n\n if (collectorEntity.nameForEmit === exportedName) {\n exportClauses.push(collectorEntity.nameForEmit);\n } else {\n exportClauses.push(`${collectorEntity.nameForEmit} as ${exportedName}`);\n }\n }\n writer.writeLine(exportClauses.join(',\\n'));\n\n writer.decreaseIndent();\n writer.writeLine('}'); // end of \"export { ... }\"\n writer.decreaseIndent();\n writer.writeLine('}'); // end of \"declare namespace { ... }\"\n }\n\n // Now emit the export statements for this entity.\n for (const exportToEmit of exportsToEmit.values()) {\n // Write any associated messages\n if (exportToEmit.associatedMessages.length > 0) {\n writer.ensureSkippedLine();\n for (const message of exportToEmit.associatedMessages) {\n ApiReportGenerator._writeLineAsComments(\n writer,\n 'Warning: ' + message.formatMessageWithoutLocation()\n );\n }\n }\n\n DtsEmitHelpers.emitNamedExport(writer, exportToEmit.exportName, entity);\n }\n writer.ensureSkippedLine();\n }\n }\n\n DtsEmitHelpers.emitStarExports(writer, collector);\n\n // Write the unassociated warnings at the bottom of the file\n const unassociatedMessages: ExtractorMessage[] =\n collector.messageRouter.fetchUnassociatedMessagesForReviewFile();\n if (unassociatedMessages.length > 0) {\n writer.ensureSkippedLine();\n ApiReportGenerator._writeLineAsComments(writer, 'Warnings were encountered during analysis:');\n ApiReportGenerator._writeLineAsComments(writer, '');\n for (const unassociatedMessage of unassociatedMessages) {\n ApiReportGenerator._writeLineAsComments(\n writer,\n unassociatedMessage.formatMessageWithLocation(collector.workingPackage.packageFolder)\n );\n }\n }\n\n if (collector.workingPackage.tsdocComment === undefined) {\n writer.ensureSkippedLine();\n ApiReportGenerator._writeLineAsComments(writer, '(No @packageDocumentation comment for this package)');\n }\n\n // Write the closing delimiter for the Markdown code fence\n writer.ensureSkippedLine();\n writer.writeLine('```');\n\n // Remove any trailing spaces\n return writer.toString().replace(ApiReportGenerator._trimSpacesRegExp, '');\n }\n\n /**\n * Before writing out a declaration, _modifySpan() applies various fixups to make it nice.\n */\n private static _modifySpan(\n collector: Collector,\n span: Span,\n entity: CollectorEntity,\n astDeclaration: AstDeclaration,\n insideTypeLiteral: boolean,\n reportVariant: ApiReportVariant\n ): void {\n // Should we process this declaration at all?\n // eslint-disable-next-line no-bitwise\n if (!ApiReportGenerator._shouldIncludeInReport(collector, astDeclaration, reportVariant)) {\n span.modification.skipAll();\n return;\n }\n\n const previousSpan: Span | undefined = span.previousSibling;\n\n let recurseChildren: boolean = true;\n let sortChildren: boolean = false;\n\n switch (span.kind) {\n case ts.SyntaxKind.JSDocComment:\n span.modification.skipAll();\n // For now, we don't transform JSDoc comment nodes at all\n recurseChildren = false;\n break;\n\n case ts.SyntaxKind.ExportKeyword:\n case ts.SyntaxKind.DefaultKeyword:\n case ts.SyntaxKind.DeclareKeyword:\n // Delete any explicit \"export\" or \"declare\" keywords -- we will re-add them below\n span.modification.skipAll();\n break;\n\n case ts.SyntaxKind.InterfaceKeyword:\n case ts.SyntaxKind.ClassKeyword:\n case ts.SyntaxKind.EnumKeyword:\n case ts.SyntaxKind.NamespaceKeyword:\n case ts.SyntaxKind.ModuleKeyword:\n case ts.SyntaxKind.TypeKeyword:\n case ts.SyntaxKind.FunctionKeyword:\n // Replace the stuff we possibly deleted above\n let replacedModifiers: string = '';\n\n if (entity.shouldInlineExport) {\n replacedModifiers = 'export ' + replacedModifiers;\n }\n\n if (previousSpan && previousSpan.kind === ts.SyntaxKind.SyntaxList) {\n // If there is a previous span of type SyntaxList, then apply it before any other modifiers\n // (e.g. \"abstract\") that appear there.\n previousSpan.modification.prefix = replacedModifiers + previousSpan.modification.prefix;\n } else {\n // Otherwise just stick it in front of this span\n span.modification.prefix = replacedModifiers + span.modification.prefix;\n }\n break;\n\n case ts.SyntaxKind.SyntaxList:\n if (span.parent) {\n if (AstDeclaration.isSupportedSyntaxKind(span.parent.kind)) {\n // If the immediate parent is an API declaration, and the immediate children are API declarations,\n // then sort the children alphabetically\n sortChildren = true;\n } else if (span.parent.kind === ts.SyntaxKind.ModuleBlock) {\n // Namespaces are special because their chain goes ModuleDeclaration -> ModuleBlock -> SyntaxList\n sortChildren = true;\n }\n }\n break;\n\n case ts.SyntaxKind.VariableDeclaration:\n if (!span.parent) {\n // The VariableDeclaration node is part of a VariableDeclarationList, however\n // the Entry.followedSymbol points to the VariableDeclaration part because\n // multiple definitions might share the same VariableDeclarationList.\n //\n // Since we are emitting a separate declaration for each one, we need to look upwards\n // in the ts.Node tree and write a copy of the enclosing VariableDeclarationList\n // content (e.g. \"var\" from \"var x=1, y=2\").\n const list: ts.VariableDeclarationList | undefined = TypeScriptHelpers.matchAncestor(span.node, [\n ts.SyntaxKind.VariableDeclarationList,\n ts.SyntaxKind.VariableDeclaration\n ]);\n if (!list) {\n // This should not happen unless the compiler API changes somehow\n throw new InternalError('Unsupported variable declaration');\n }\n const listPrefix: string = list\n .getSourceFile()\n .text.substring(list.getStart(), list.declarations[0].getStart());\n span.modification.prefix = listPrefix + span.modification.prefix;\n span.modification.suffix = ';';\n\n if (entity.shouldInlineExport) {\n span.modification.prefix = 'export ' + span.modification.prefix;\n }\n }\n break;\n\n case ts.SyntaxKind.Identifier:\n const referencedEntity: CollectorEntity | undefined = collector.tryGetEntityForNode(\n span.node as ts.Identifier\n );\n\n if (referencedEntity) {\n if (!referencedEntity.nameForEmit) {\n // This should never happen\n throw new InternalError('referencedEntry.nameForEmit is undefined');\n }\n\n span.modification.prefix = referencedEntity.nameForEmit;\n // For debugging:\n // span.modification.prefix += '/*R=FIX*/';\n } else {\n // For debugging:\n // span.modification.prefix += '/*R=KEEP*/';\n }\n\n break;\n\n case ts.SyntaxKind.TypeLiteral:\n insideTypeLiteral = true;\n break;\n\n case ts.SyntaxKind.ImportType:\n DtsEmitHelpers.modifyImportTypeSpan(\n collector,\n span,\n astDeclaration,\n (childSpan, childAstDeclaration) => {\n ApiReportGenerator._modifySpan(\n collector,\n childSpan,\n entity,\n childAstDeclaration,\n insideTypeLiteral,\n reportVariant\n );\n }\n );\n break;\n }\n\n if (recurseChildren) {\n for (const child of span.children) {\n let childAstDeclaration: AstDeclaration = astDeclaration;\n\n if (AstDeclaration.isSupportedSyntaxKind(child.kind)) {\n childAstDeclaration = collector.astSymbolTable.getChildAstDeclarationByNode(\n child.node,\n astDeclaration\n );\n\n if (ApiReportGenerator._shouldIncludeInReport(collector, childAstDeclaration, reportVariant)) {\n if (sortChildren) {\n span.modification.sortChildren = true;\n child.modification.sortKey = Collector.getSortKeyIgnoringUnderscore(\n childAstDeclaration.astSymbol.localName\n );\n }\n\n if (!insideTypeLiteral) {\n const messagesToReport: ExtractorMessage[] =\n collector.messageRouter.fetchAssociatedMessagesForReviewFile(childAstDeclaration);\n\n // NOTE: This generates ae-undocumented messages as a side effect\n const aedocSynopsis: string = ApiReportGenerator._getAedocSynopsis(\n collector,\n childAstDeclaration,\n messagesToReport\n );\n\n child.modification.prefix = aedocSynopsis + child.modification.prefix;\n }\n }\n }\n\n ApiReportGenerator._modifySpan(\n collector,\n child,\n entity,\n childAstDeclaration,\n insideTypeLiteral,\n reportVariant\n );\n }\n }\n }\n\n private static _shouldIncludeInReport(\n collector: Collector,\n astDeclaration: AstDeclaration,\n reportVariant: ApiReportVariant\n ): boolean {\n // Private declarations are not included in the API report\n // eslint-disable-next-line no-bitwise\n if ((astDeclaration.modifierFlags & ts.ModifierFlags.Private) !== 0) {\n return false;\n }\n\n const apiItemMetadata: ApiItemMetadata = collector.fetchApiItemMetadata(astDeclaration);\n\n // No specified release tag is considered the same as `@public`.\n const releaseTag: ReleaseTag =\n apiItemMetadata.effectiveReleaseTag === ReleaseTag.None\n ? ReleaseTag.Public\n : apiItemMetadata.effectiveReleaseTag;\n\n // If the declaration has a release tag that is not in scope, omit it from the report.\n switch (reportVariant) {\n case 'complete':\n return true;\n case 'alpha':\n return releaseTag >= ReleaseTag.Alpha;\n case 'beta':\n return releaseTag >= ReleaseTag.Beta;\n case 'public':\n return releaseTag === ReleaseTag.Public;\n default:\n throw new Error(`Unrecognized release level: ${reportVariant}`);\n }\n }\n\n /**\n * For declarations marked as `@preapproved`, this is used instead of _modifySpan().\n */\n private static _modifySpanForPreapproved(span: Span): void {\n // Match something like this:\n //\n // ClassDeclaration:\n // SyntaxList:\n // ExportKeyword: pre=[export] sep=[ ]\n // DeclareKeyword: pre=[declare] sep=[ ]\n // ClassKeyword: pre=[class] sep=[ ]\n // Identifier: pre=[_PreapprovedClass] sep=[ ]\n // FirstPunctuation: pre=[{] sep=[\\n\\n ]\n // SyntaxList:\n // ...\n // CloseBraceToken: pre=[}]\n //\n // or this:\n // ModuleDeclaration:\n // SyntaxList:\n // ExportKeyword: pre=[export] sep=[ ]\n // DeclareKeyword: pre=[declare] sep=[ ]\n // NamespaceKeyword: pre=[namespace] sep=[ ]\n // Identifier: pre=[_PreapprovedNamespace] sep=[ ]\n // ModuleBlock:\n // FirstPunctuation: pre=[{] sep=[\\n\\n ]\n // SyntaxList:\n // ...\n // CloseBraceToken: pre=[}]\n //\n // And reduce it to something like this:\n //\n // // @internal (undocumented)\n // class _PreapprovedClass { /* (preapproved) */ }\n //\n\n let skipRest: boolean = false;\n for (const child of span.children) {\n if (skipRest || child.kind === ts.SyntaxKind.SyntaxList || child.kind === ts.SyntaxKind.JSDocComment) {\n child.modification.skipAll();\n }\n if (child.kind === ts.SyntaxKind.Identifier) {\n skipRest = true;\n child.modification.omitSeparatorAfter = true;\n child.modification.suffix = ' { /* (preapproved) */ }';\n }\n }\n }\n\n /**\n * Writes a synopsis of the AEDoc comments, which indicates the release tag,\n * whether the item has been documented, and any warnings that were detected\n * by the analysis.\n */\n private static _getAedocSynopsis(\n collector: Collector,\n astDeclaration: AstDeclaration,\n messagesToReport: ExtractorMessage[]\n ): string {\n const writer: IndentedWriter = new IndentedWriter();\n\n for (const message of messagesToReport) {\n ApiReportGenerator._writeLineAsComments(writer, 'Warning: ' + message.formatMessageWithoutLocation());\n }\n\n if (!collector.isAncillaryDeclaration(astDeclaration)) {\n const footerParts: string[] = [];\n const apiItemMetadata: ApiItemMetadata = collector.fetchApiItemMetadata(astDeclaration);\n if (!apiItemMetadata.releaseTagSameAsParent) {\n if (apiItemMetadata.effectiveReleaseTag !== ReleaseTag.None) {\n footerParts.push(ReleaseTag.getTagName(apiItemMetadata.effectiveReleaseTag));\n }\n }\n\n if (apiItemMetadata.isSealed) {\n footerParts.push('@sealed');\n }\n\n if (apiItemMetadata.isVirtual) {\n footerParts.push('@virtual');\n }\n\n if (apiItemMetadata.isOverride) {\n footerParts.push('@override');\n }\n\n if (apiItemMetadata.isEventProperty) {\n footerParts.push('@eventProperty');\n }\n\n if (apiItemMetadata.tsdocComment) {\n if (apiItemMetadata.tsdocComment.deprecatedBlock) {\n footerParts.push('@deprecated');\n }\n }\n\n if (apiItemMetadata.undocumented) {\n footerParts.push('(undocumented)');\n\n collector.messageRouter.addAnalyzerIssue(\n ExtractorMessageId.Undocumented,\n `Missing documentation for \"${astDeclaration.astSymbol.localName}\".`,\n astDeclaration\n );\n }\n\n if (footerParts.length > 0) {\n if (messagesToReport.length > 0) {\n ApiReportGenerator._writeLineAsComments(writer, ''); // skip a line after the warnings\n }\n\n ApiReportGenerator._writeLineAsComments(writer, footerParts.join(' '));\n }\n }\n\n return writer.toString();\n }\n\n private static _writeLineAsComments(writer: IndentedWriter, line: string): void {\n const lines: string[] = Text.convertToLf(line).split('\\n');\n for (const realLine of lines) {\n writer.write('// ');\n writer.write(realLine);\n writer.writeLine();\n }\n }\n}\n"]}
1
+ {"version":3,"file":"ApiReportGenerator.js","sourceRoot":"","sources":["../../src/generators/ApiReportGenerator.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAE3D,+CAAiC;AACjC,oEAAmE;AACnE,wEAA4D;AAE5D,sDAAmD;AACnD,qEAAkE;AAClE,2CAAwC;AAExC,+DAA4D;AAE5D,qDAAkD;AAClD,qDAAkD;AAElD,qDAAkD;AAClD,qDAAkD;AAClD,uEAAoE;AAGpE,yFAAsF;AACtF,kEAA+D;AAG/D,MAAa,kBAAkB;IAG7B;;;;;;OAMG;IACI,MAAM,CAAC,4BAA4B,CACxC,iBAAyB,EACzB,mBAA2B;QAE3B,wCAAwC;QACxC,MAAM,gBAAgB,GAAW,iBAAiB,CAAC,OAAO,CAAC,QAAQ,EAAE,GAAG,CAAC,CAAC;QAC1E,MAAM,kBAAkB,GAAW,m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CAAC,SAAS,EAAE,CAAC;QACrB,CAAC;IACH,CAAC;;AAvmBH,gDAwmBC;AAvmBgB,oCAAiB,GAAW,OAAO,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.\n// See LICENSE in the project root for license information.\n\nimport * as ts from 'typescript';\nimport { Text, InternalError } from '@rushstack/node-core-library';\nimport { ReleaseTag } from '@microsoft/api-extractor-model';\n\nimport { Collector } from '../collector/Collector';\nimport { TypeScriptHelpers } from '../analyzer/TypeScriptHelpers';\nimport { Span } from '../analyzer/Span';\nimport type { CollectorEntity } from '../collector/CollectorEntity';\nimport { AstDeclaration } from '../analyzer/AstDeclaration';\nimport type { ApiItemMetadata } from '../collector/ApiItemMetadata';\nimport { AstImport } from '../analyzer/AstImport';\nimport { AstSymbol } from '../analyzer/AstSymbol';\nimport type { ExtractorMessage } from '../api/ExtractorMessage';\nimport { IndentedWriter } from './IndentedWriter';\nimport { DtsEmitHelpers } from './DtsEmitHelpers';\nimport { AstNamespaceImport } from '../analyzer/AstNamespaceImport';\nimport type { AstEntity } from '../analyzer/AstEntity';\nimport type { IAstModuleExportInfo } from '../analyzer/AstModule';\nimport { SourceFileLocationFormatter } from '../analyzer/SourceFileLocationFormatter';\nimport { ExtractorMessageId } from '../api/ExtractorMessageId';\nimport type { ApiReportVariant } from '../api/IConfigFile';\n\nexport class ApiReportGenerator {\n private static _trimSpacesRegExp: RegExp = / +$/gm;\n\n /**\n * Compares the contents of two API files that were created using ApiFileGenerator,\n * and returns true if they are equivalent. Note that these files are not normally edited\n * by a human; the \"equivalence\" comparison here is intended to ignore spurious changes that\n * might be introduced by a tool, e.g. Git newline normalization or an editor that strips\n * whitespace when saving.\n */\n public static areEquivalentApiFileContents(\n actualFileContent: string,\n expectedFileContent: string\n ): boolean {\n // NOTE: \"\\s\" also matches \"\\r\" and \"\\n\"\n const normalizedActual: string = actualFileContent.replace(/[\\s]+/g, ' ');\n const normalizedExpected: string = expectedFileContent.replace(/[\\s]+/g, ' ');\n return normalizedActual === normalizedExpected;\n }\n\n /**\n * Generates and returns the API report contents as a string.\n *\n * @param reportVariant - The release level with which the report is associated.\n * Can also be viewed as the minimal release level of items that should be included in the report.\n */\n public static generateReviewFileContent(collector: Collector, reportVariant: ApiReportVariant): string {\n const writer: IndentedWriter = new IndentedWriter();\n writer.trimLeadingSpaces = true;\n\n function capitalizeFirstLetter(input: string): string {\n return input === '' ? '' : `${input[0].toLocaleUpperCase()}${input.slice(1)}`;\n }\n\n // For backwards compatibility, don't emit \"complete\" in report text for untrimmed reports.\n const releaseLevelPrefix: string =\n reportVariant === 'complete' ? '' : `${capitalizeFirstLetter(reportVariant)} `;\n writer.writeLine(\n [\n `## ${releaseLevelPrefix}API Report File for \"${collector.workingPackage.name}\"`,\n ``,\n `> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).`,\n ``\n ].join('\\n')\n );\n\n // Write the opening delimiter for the Markdown code fence\n writer.writeLine('```ts\\n');\n\n // Emit the triple slash directives\n for (const typeDirectiveReference of Array.from(collector.dtsTypeReferenceDirectives).sort()) {\n // https://github.com/microsoft/TypeScript/blob/611ebc7aadd7a44a4c0447698bfda9222a78cb66/src/compiler/declarationEmitter.ts#L162\n writer.writeLine(`/// <reference types=\"${typeDirectiveReference}\" />`);\n }\n for (const libDirectiveReference of Array.from(collector.dtsLibReferenceDirectives).sort()) {\n writer.writeLine(`/// <reference lib=\"${libDirectiveReference}\" />`);\n }\n writer.ensureSkippedLine();\n\n // Emit the imports\n for (const entity of collector.entities) {\n if (entity.astEntity instanceof AstImport) {\n DtsEmitHelpers.emitImport(writer, entity, entity.astEntity);\n }\n }\n writer.ensureSkippedLine();\n\n // Emit the regular declarations\n for (const entity of collector.entities) {\n const astEntity: AstEntity = entity.astEntity;\n if (entity.consumable || collector.extractorConfig.apiReportIncludeForgottenExports) {\n // First, collect the list of export names for this symbol. When reporting messages with\n // ExtractorMessage.properties.exportName, this will enable us to emit the warning comments alongside\n // the associated export statement.\n interface IExportToEmit {\n readonly exportName: string;\n readonly associatedMessages: ExtractorMessage[];\n }\n const exportsToEmit: Map<string, IExportToEmit> = new Map<string, IExportToEmit>();\n\n for (const exportName of entity.exportNames) {\n if (!entity.shouldInlineExport) {\n exportsToEmit.set(exportName, { exportName, associatedMessages: [] });\n }\n }\n\n if (astEntity instanceof AstSymbol) {\n // Emit all the declarations for this entity\n for (const astDeclaration of astEntity.astDeclarations || []) {\n // Get the messages associated with this declaration\n const fetchedMessages: ExtractorMessage[] =\n collector.messageRouter.fetchAssociatedMessagesForReviewFile(astDeclaration);\n\n // Peel off the messages associated with an export statement and store them\n // in IExportToEmit.associatedMessages (to be processed later). The remaining messages will\n // added to messagesToReport, to be emitted next to the declaration instead of the export statement.\n const messagesToReport: ExtractorMessage[] = [];\n for (const message of fetchedMessages) {\n if (message.properties.exportName) {\n const exportToEmit: IExportToEmit | undefined = exportsToEmit.get(\n message.properties.exportName\n );\n if (exportToEmit) {\n exportToEmit.associatedMessages.push(message);\n continue;\n }\n }\n messagesToReport.push(message);\n }\n\n if (this._shouldIncludeInReport(collector, astDeclaration, reportVariant)) {\n writer.ensureSkippedLine();\n writer.write(ApiReportGenerator._getAedocSynopsis(collector, astDeclaration, messagesToReport));\n\n const span: Span = new Span(astDeclaration.declaration);\n\n const apiItemMetadata: ApiItemMetadata = collector.fetchApiItemMetadata(astDeclaration);\n if (apiItemMetadata.isPreapproved) {\n ApiReportGenerator._modifySpanForPreapproved(span);\n } else {\n ApiReportGenerator._modifySpan(collector, span, entity, astDeclaration, false, reportVariant);\n }\n\n span.writeModifiedText(writer);\n writer.ensureNewLine();\n }\n }\n }\n\n if (astEntity instanceof AstNamespaceImport) {\n const astModuleExportInfo: IAstModuleExportInfo = astEntity.fetchAstModuleExportInfo(collector);\n\n if (entity.nameForEmit === undefined) {\n // This should never happen\n throw new InternalError('referencedEntry.nameForEmit is undefined');\n }\n\n if (astModuleExportInfo.starExportedExternalModules.size > 0) {\n // We could support this, but we would need to find a way to safely represent it.\n throw new Error(\n `The ${entity.nameForEmit} namespace import includes a star export, which is not supported:\\n` +\n SourceFileLocationFormatter.formatDeclaration(astEntity.declaration)\n );\n }\n\n // Emit a synthetic declaration for the namespace. It will look like this:\n //\n // declare namespace example {\n // export {\n // f1,\n // f2\n // }\n // }\n //\n // Note that we do not try to relocate f1()/f2() to be inside the namespace because other type\n // signatures may reference them directly (without using the namespace qualifier).\n\n writer.ensureSkippedLine();\n writer.writeLine(`declare namespace ${entity.nameForEmit} {`);\n\n // all local exports of local imported module are just references to top-level declarations\n writer.increaseIndent();\n writer.writeLine('export {');\n writer.increaseIndent();\n\n const exportClauses: string[] = [];\n for (const [exportedName, exportedEntity] of astModuleExportInfo.exportedLocalEntities) {\n const collectorEntity: CollectorEntity | undefined =\n collector.tryGetCollectorEntity(exportedEntity);\n if (collectorEntity === undefined) {\n // This should never happen\n // top-level exports of local imported module should be added as collector entities before\n throw new InternalError(\n `Cannot find collector entity for ${entity.nameForEmit}.${exportedEntity.localName}`\n );\n }\n\n if (collectorEntity.nameForEmit === exportedName) {\n exportClauses.push(collectorEntity.nameForEmit);\n } else {\n exportClauses.push(`${collectorEntity.nameForEmit} as ${exportedName}`);\n }\n }\n writer.writeLine(exportClauses.join(',\\n'));\n\n writer.decreaseIndent();\n writer.writeLine('}'); // end of \"export { ... }\"\n writer.decreaseIndent();\n writer.writeLine('}'); // end of \"declare namespace { ... }\"\n }\n\n // Now emit the export statements for this entity.\n for (const exportToEmit of exportsToEmit.values()) {\n // Write any associated messages\n if (exportToEmit.associatedMessages.length > 0) {\n writer.ensureSkippedLine();\n for (const message of exportToEmit.associatedMessages) {\n ApiReportGenerator._writeLineAsComments(\n writer,\n 'Warning: ' + message.formatMessageWithoutLocation()\n );\n }\n }\n\n DtsEmitHelpers.emitNamedExport(writer, exportToEmit.exportName, entity);\n }\n writer.ensureSkippedLine();\n }\n }\n\n DtsEmitHelpers.emitStarExports(writer, collector);\n\n // Write the unassociated warnings at the bottom of the file\n const unassociatedMessages: ExtractorMessage[] =\n collector.messageRouter.fetchUnassociatedMessagesForReviewFile();\n if (unassociatedMessages.length > 0) {\n writer.ensureSkippedLine();\n ApiReportGenerator._writeLineAsComments(writer, 'Warnings were encountered during analysis:');\n ApiReportGenerator._writeLineAsComments(writer, '');\n for (const unassociatedMessage of unassociatedMessages) {\n ApiReportGenerator._writeLineAsComments(\n writer,\n unassociatedMessage.formatMessageWithLocation(collector.workingPackage.packageFolder)\n );\n }\n }\n\n if (collector.workingPackage.tsdocComment === undefined) {\n writer.ensureSkippedLine();\n ApiReportGenerator._writeLineAsComments(writer, '(No @packageDocumentation comment for this package)');\n }\n\n // Write the closing delimiter for the Markdown code fence\n writer.ensureSkippedLine();\n writer.writeLine('```');\n\n // Remove any trailing spaces\n return writer.toString().replace(ApiReportGenerator._trimSpacesRegExp, '');\n }\n\n /**\n * Before writing out a declaration, _modifySpan() applies various fixups to make it nice.\n */\n private static _modifySpan(\n collector: Collector,\n span: Span,\n entity: CollectorEntity,\n astDeclaration: AstDeclaration,\n insideTypeLiteral: boolean,\n reportVariant: ApiReportVariant\n ): void {\n // Should we process this declaration at all?\n // eslint-disable-next-line no-bitwise\n if (!ApiReportGenerator._shouldIncludeInReport(collector, astDeclaration, reportVariant)) {\n span.modification.skipAll();\n return;\n }\n\n const previousSpan: Span | undefined = span.previousSibling;\n\n let recurseChildren: boolean = true;\n let sortChildren: boolean = false;\n\n switch (span.kind) {\n case ts.SyntaxKind.JSDocComment:\n span.modification.skipAll();\n // For now, we don't transform JSDoc comment nodes at all\n recurseChildren = false;\n break;\n\n case ts.SyntaxKind.ExportKeyword:\n case ts.SyntaxKind.DefaultKeyword:\n case ts.SyntaxKind.DeclareKeyword:\n // Delete any explicit \"export\" or \"declare\" keywords -- we will re-add them below\n span.modification.skipAll();\n break;\n\n case ts.SyntaxKind.InterfaceKeyword:\n case ts.SyntaxKind.ClassKeyword:\n case ts.SyntaxKind.EnumKeyword:\n case ts.SyntaxKind.NamespaceKeyword:\n case ts.SyntaxKind.ModuleKeyword:\n case ts.SyntaxKind.TypeKeyword:\n case ts.SyntaxKind.FunctionKeyword:\n // Replace the stuff we possibly deleted above\n let replacedModifiers: string = '';\n\n if (entity.shouldInlineExport) {\n replacedModifiers = 'export ' + replacedModifiers;\n }\n\n if (previousSpan && previousSpan.kind === ts.SyntaxKind.SyntaxList) {\n // If there is a previous span of type SyntaxList, then apply it before any other modifiers\n // (e.g. \"abstract\") that appear there.\n previousSpan.modification.prefix = replacedModifiers + previousSpan.modification.prefix;\n } else {\n // Otherwise just stick it in front of this span\n span.modification.prefix = replacedModifiers + span.modification.prefix;\n }\n break;\n\n case ts.SyntaxKind.SyntaxList:\n if (span.parent) {\n if (AstDeclaration.isSupportedSyntaxKind(span.parent.kind)) {\n // If the immediate parent is an API declaration, and the immediate children are API declarations,\n // then sort the children alphabetically\n sortChildren = true;\n } else if (span.parent.kind === ts.SyntaxKind.ModuleBlock) {\n // Namespaces are special because their chain goes ModuleDeclaration -> ModuleBlock -> SyntaxList\n sortChildren = true;\n }\n }\n break;\n\n case ts.SyntaxKind.VariableDeclaration:\n if (!span.parent) {\n // The VariableDeclaration node is part of a VariableDeclarationList, however\n // the Entry.followedSymbol points to the VariableDeclaration part because\n // multiple definitions might share the same VariableDeclarationList.\n //\n // Since we are emitting a separate declaration for each one, we need to look upwards\n // in the ts.Node tree and write a copy of the enclosing VariableDeclarationList\n // content (e.g. \"var\" from \"var x=1, y=2\").\n const list: ts.VariableDeclarationList | undefined = TypeScriptHelpers.matchAncestor(span.node, [\n ts.SyntaxKind.VariableDeclarationList,\n ts.SyntaxKind.VariableDeclaration\n ]);\n if (!list) {\n // This should not happen unless the compiler API changes somehow\n throw new InternalError('Unsupported variable declaration');\n }\n const listPrefix: string = list\n .getSourceFile()\n .text.substring(list.getStart(), list.declarations[0].getStart());\n span.modification.prefix = listPrefix + span.modification.prefix;\n span.modification.suffix = ';';\n\n if (entity.shouldInlineExport) {\n span.modification.prefix = 'export ' + span.modification.prefix;\n }\n }\n break;\n\n case ts.SyntaxKind.Identifier:\n const referencedEntity: CollectorEntity | undefined = collector.tryGetEntityForNode(\n span.node as ts.Identifier\n );\n\n if (referencedEntity) {\n if (!referencedEntity.nameForEmit) {\n // This should never happen\n throw new InternalError('referencedEntry.nameForEmit is undefined');\n }\n\n span.modification.prefix = referencedEntity.nameForEmit;\n // For debugging:\n // span.modification.prefix += '/*R=FIX*/';\n } else {\n // For debugging:\n // span.modification.prefix += '/*R=KEEP*/';\n }\n\n break;\n\n case ts.SyntaxKind.TypeLiteral:\n insideTypeLiteral = true;\n break;\n\n case ts.SyntaxKind.ImportType:\n DtsEmitHelpers.modifyImportTypeSpan(\n collector,\n span,\n astDeclaration,\n (childSpan, childAstDeclaration) => {\n ApiReportGenerator._modifySpan(\n collector,\n childSpan,\n entity,\n childAstDeclaration,\n insideTypeLiteral,\n reportVariant\n );\n }\n );\n break;\n }\n\n if (recurseChildren) {\n for (const child of span.children) {\n let childAstDeclaration: AstDeclaration = astDeclaration;\n\n if (AstDeclaration.isSupportedSyntaxKind(child.kind)) {\n childAstDeclaration = collector.astSymbolTable.getChildAstDeclarationByNode(\n child.node,\n astDeclaration\n );\n\n if (ApiReportGenerator._shouldIncludeInReport(collector, childAstDeclaration, reportVariant)) {\n if (sortChildren) {\n span.modification.sortChildren = true;\n child.modification.sortKey = Collector.getSortKeyIgnoringUnderscore(\n childAstDeclaration.astSymbol.localName\n );\n }\n\n if (!insideTypeLiteral) {\n const messagesToReport: ExtractorMessage[] =\n collector.messageRouter.fetchAssociatedMessagesForReviewFile(childAstDeclaration);\n\n // NOTE: This generates ae-undocumented messages as a side effect\n const aedocSynopsis: string = ApiReportGenerator._getAedocSynopsis(\n collector,\n childAstDeclaration,\n messagesToReport\n );\n\n child.modification.prefix = aedocSynopsis + child.modification.prefix;\n }\n }\n }\n\n ApiReportGenerator._modifySpan(\n collector,\n child,\n entity,\n childAstDeclaration,\n insideTypeLiteral,\n reportVariant\n );\n }\n }\n }\n\n private static _shouldIncludeInReport(\n collector: Collector,\n astDeclaration: AstDeclaration,\n reportVariant: ApiReportVariant\n ): boolean {\n // Private declarations are not included in the API report\n // eslint-disable-next-line no-bitwise\n if ((astDeclaration.modifierFlags & ts.ModifierFlags.Private) !== 0) {\n return false;\n }\n\n const apiItemMetadata: ApiItemMetadata = collector.fetchApiItemMetadata(astDeclaration);\n\n // No specified release tag is considered the same as `@public`.\n const releaseTag: ReleaseTag =\n apiItemMetadata.effectiveReleaseTag === ReleaseTag.None\n ? ReleaseTag.Public\n : apiItemMetadata.effectiveReleaseTag;\n\n // If the declaration has a release tag that is not in scope, omit it from the report.\n switch (reportVariant) {\n case 'complete':\n return true;\n case 'alpha':\n return releaseTag >= ReleaseTag.Alpha;\n case 'beta':\n return releaseTag >= ReleaseTag.Beta;\n case 'public':\n return releaseTag === ReleaseTag.Public;\n default:\n throw new Error(`Unrecognized release level: ${reportVariant}`);\n }\n }\n\n /**\n * For declarations marked as `@preapproved`, this is used instead of _modifySpan().\n */\n private static _modifySpanForPreapproved(span: Span): void {\n // Match something like this:\n //\n // ClassDeclaration:\n // SyntaxList:\n // ExportKeyword: pre=[export] sep=[ ]\n // DeclareKeyword: pre=[declare] sep=[ ]\n // ClassKeyword: pre=[class] sep=[ ]\n // Identifier: pre=[_PreapprovedClass] sep=[ ]\n // FirstPunctuation: pre=[{] sep=[\\n\\n ]\n // SyntaxList:\n // ...\n // CloseBraceToken: pre=[}]\n //\n // or this:\n // ModuleDeclaration:\n // SyntaxList:\n // ExportKeyword: pre=[export] sep=[ ]\n // DeclareKeyword: pre=[declare] sep=[ ]\n // NamespaceKeyword: pre=[namespace] sep=[ ]\n // Identifier: pre=[_PreapprovedNamespace] sep=[ ]\n // ModuleBlock:\n // FirstPunctuation: pre=[{] sep=[\\n\\n ]\n // SyntaxList:\n // ...\n // CloseBraceToken: pre=[}]\n //\n // And reduce it to something like this:\n //\n // // @internal (undocumented)\n // class _PreapprovedClass { /* (preapproved) */ }\n //\n\n let skipRest: boolean = false;\n for (const child of span.children) {\n if (skipRest || child.kind === ts.SyntaxKind.SyntaxList || child.kind === ts.SyntaxKind.JSDocComment) {\n child.modification.skipAll();\n }\n if (child.kind === ts.SyntaxKind.Identifier) {\n skipRest = true;\n child.modification.omitSeparatorAfter = true;\n child.modification.suffix = ' { /* (preapproved) */ }';\n }\n }\n }\n\n /**\n * Writes a synopsis of the AEDoc comments, which indicates the release tag,\n * whether the item has been documented, and any warnings that were detected\n * by the analysis.\n */\n private static _getAedocSynopsis(\n collector: Collector,\n astDeclaration: AstDeclaration,\n messagesToReport: ExtractorMessage[]\n ): string {\n const writer: IndentedWriter = new IndentedWriter();\n\n for (const message of messagesToReport) {\n ApiReportGenerator._writeLineAsComments(writer, 'Warning: ' + message.formatMessageWithoutLocation());\n }\n\n if (!collector.isAncillaryDeclaration(astDeclaration)) {\n const footerParts: string[] = [];\n const apiItemMetadata: ApiItemMetadata = collector.fetchApiItemMetadata(astDeclaration);\n\n // 1. Release tag (if present)\n if (!apiItemMetadata.releaseTagSameAsParent) {\n if (apiItemMetadata.effectiveReleaseTag !== ReleaseTag.None) {\n footerParts.push(ReleaseTag.getTagName(apiItemMetadata.effectiveReleaseTag));\n }\n }\n\n // 2. Enumerate configured tags, reporting standard system tags first and then other configured tags.\n // Note that the ordering we handle the standard tags is important for backwards compatibility.\n // Also note that we had special mechanisms for checking whether or not an item is documented with these tags,\n // so they are checked specially.\n const {\n '@sealed': reportSealedTag,\n '@virtual': reportVirtualTag,\n '@override': reportOverrideTag,\n '@eventProperty': reportEventPropertyTag,\n '@deprecated': reportDeprecatedTag,\n ...otherTagsToReport\n } = collector.extractorConfig.tagsToReport;\n\n // 2.a Check for standard tags and report those that are both configured and present in the metadata.\n if (reportSealedTag && apiItemMetadata.isSealed) {\n footerParts.push('@sealed');\n }\n if (reportVirtualTag && apiItemMetadata.isVirtual) {\n footerParts.push('@virtual');\n }\n if (reportOverrideTag && apiItemMetadata.isOverride) {\n footerParts.push('@override');\n }\n if (reportEventPropertyTag && apiItemMetadata.isEventProperty) {\n footerParts.push('@eventProperty');\n }\n if (reportDeprecatedTag && apiItemMetadata.tsdocComment?.deprecatedBlock) {\n footerParts.push('@deprecated');\n }\n\n // 2.b Check for other configured tags and report those that are present in the tsdoc metadata.\n for (const [tag, reportTag] of Object.entries(otherTagsToReport)) {\n if (reportTag) {\n // If the tag was not handled specially, check if it is present in the metadata.\n if (apiItemMetadata.tsdocComment?.customBlocks.some((block) => block.blockTag.tagName === tag)) {\n footerParts.push(tag);\n } else if (apiItemMetadata.tsdocComment?.modifierTagSet.hasTagName(tag)) {\n footerParts.push(tag);\n }\n }\n }\n\n // 3. If the item is undocumented, append notice at the end of the list\n if (apiItemMetadata.undocumented) {\n footerParts.push('(undocumented)');\n\n collector.messageRouter.addAnalyzerIssue(\n ExtractorMessageId.Undocumented,\n `Missing documentation for \"${astDeclaration.astSymbol.localName}\".`,\n astDeclaration\n );\n }\n\n if (footerParts.length > 0) {\n if (messagesToReport.length > 0) {\n ApiReportGenerator._writeLineAsComments(writer, ''); // skip a line after the warnings\n }\n\n ApiReportGenerator._writeLineAsComments(writer, footerParts.join(' '));\n }\n }\n\n return writer.toString();\n }\n\n private static _writeLineAsComments(writer: IndentedWriter, line: string): void {\n const lines: string[] = Text.convertToLf(line).split('\\n');\n for (const realLine of lines) {\n writer.write('// ');\n writer.write(realLine);\n writer.writeLine();\n }\n }\n}\n"]}
@@ -30,7 +30,6 @@
30
30
 
31
31
  "dtsRollup": {
32
32
  // ("enabled" is required)
33
-
34
33
  "untrimmedFilePath": "<projectFolder>/dist/<unscopedPackageName>.d.ts",
35
34
  "alphaTrimmedFilePath": "",
36
35
  "betaTrimmedFilePath": "",
@@ -106,6 +106,17 @@
106
106
  "includeForgottenExports": {
107
107
  "description": "Whether \"forgotten exports\" should be included in the API report file. Forgotten exports are declarations flagged with `ae-forgotten-export` warnings. See https://api-extractor.com/pages/messages/ae-forgotten-export/ to learn more.",
108
108
  "type": "boolean"
109
+ },
110
+
111
+ "tagsToReport": {
112
+ "description": "Specifies a list of TSDoc tags that should be reported in the API report file for items whose documentation contains them. This can be used to include standard TSDoc tags or custom ones. Specified tag names must begin with \"@\". By default, the following tags are reported: [@sealed, @virtual, @override, @eventProperty, @deprecated]. Tags will appear in the order they are specified in this list. Note that an item's release tag will always reported; this behavior cannot be overridden.",
113
+ "type": "object",
114
+ "patternProperties": {
115
+ "^@[^\\s]*$": {
116
+ "type": "boolean"
117
+ }
118
+ },
119
+ "additionalProperties": false
109
120
  }
110
121
  },
111
122
  "required": ["enabled"],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@microsoft/api-extractor",
3
- "version": "7.52.2",
3
+ "version": "7.52.3",
4
4
  "description": "Analyze the exported API for a TypeScript library and generate reviews, documentation, and .d.ts rollups",
5
5
  "keywords": [
6
6
  "typescript",
@@ -40,10 +40,10 @@
40
40
  "semver": "~7.5.4",
41
41
  "source-map": "~0.6.1",
42
42
  "typescript": "5.8.2",
43
+ "@rushstack/node-core-library": "5.13.0",
43
44
  "@microsoft/api-extractor-model": "7.30.5",
44
- "@rushstack/ts-command-line": "4.23.7",
45
45
  "@rushstack/rig-package": "0.5.3",
46
- "@rushstack/node-core-library": "5.13.0",
46
+ "@rushstack/ts-command-line": "4.23.7",
47
47
  "@rushstack/terminal": "0.15.2"
48
48
  },
49
49
  "devDependencies": {