File tree Expand file tree Collapse file tree 3 files changed +20
-1
lines changed Expand file tree Collapse file tree 3 files changed +20
-1
lines changed Original file line number Diff line number Diff line change @@ -136,6 +136,14 @@ export interface IExtractorConfigPrepareOptions {
136
136
* `@microsoft/api-extractor/extends/tsdoc-base.json`.
137
137
*/
138
138
tsdocConfigFile ?: TSDocConfigFile ;
139
+
140
+ /**
141
+ * When preparing the configuration object, folder and file paths referenced in the configuration are checked
142
+ * for existence, and an error is reported if they are not found. This option can be used to disable this
143
+ * check for the main entry point module. This may be useful when preparing a configuration file for an
144
+ * un-built project.
145
+ */
146
+ ignoreMissingEntryPoint ?: boolean ;
139
147
}
140
148
141
149
interface IExtractorConfigParameters {
@@ -811,7 +819,7 @@ export class ExtractorConfig {
811
819
) ;
812
820
}
813
821
814
- if ( ! FileSystem . exists ( mainEntryPointFilePath ) ) {
822
+ if ( ! options . ignoreMissingEntryPoint && ! FileSystem . exists ( mainEntryPointFilePath ) ) {
815
823
throw new Error ( 'The "mainEntryPointFilePath" path does not exist: ' + mainEntryPointFilePath ) ;
816
824
}
817
825
Original file line number Diff line number Diff line change
1
+ {
2
+ "changes" : [
3
+ {
4
+ "packageName" : " @microsoft/api-extractor" ,
5
+ "comment" : " Add support for the \" ignoreMissingEntryPoint\" ExtractorConfig option to allow for loading an ExtractorConfig before the target project is built." ,
6
+ "type" : " minor"
7
+ }
8
+ ],
9
+ "packageName" : " @microsoft/api-extractor"
10
+ }
Original file line number Diff line number Diff line change @@ -243,6 +243,7 @@ export interface IExtractorConfigLoadForFolderOptions {
243
243
export interface IExtractorConfigPrepareOptions {
244
244
configObject: IConfigFile ;
245
245
configObjectFullPath: string | undefined ;
246
+ ignoreMissingEntryPoint? : boolean ;
246
247
packageJson? : INodePackageJson | undefined ;
247
248
packageJsonFullPath: string | undefined ;
248
249
projectFolderLookupToken? : string ;
You can’t perform that action at this time.
0 commit comments