/** * @internal * * @remarks * If this schema is updated, dependant schemas MUST also be updated, including the spfx-serve.schema.json. * The spfx-serve.schema.json is the serve.schema.json file with the spfx-specific properties included. The * merge is simple, but must be done manually whenever the serve.schema.json file is changed. */ export interface IServeTaskConfig { /** * API server configuration */ api?: { /** * The port on which to run the API server */ port: number; /** * The path to the script to run as the API server */ entryPath: string; }; /** * The path to the page which should open automatically after this task completes. If you prefer no page to be * launched, run the build with the "--nobrowser" flag */ initialPage?: string; /** * The port on which to host the file server. */ port?: number; /** * The name of the host on which serve is running. Defaults to 'localhost' */ hostname?: string; /** * IP address of the host on which serve is running. * @remarks * This parameter is helpful when using Docker containers. For example, to set the serve host as '0.0.0.0'. */ ipAddress?: string; /** * If true, the server should run on HTTPS */ https?: boolean; /** * The project relative path or array of paths to serve static content from. */ contentBase?: string | string[]; /** * The URL path to serve static content requests from. */ contentBasePublicPath?: string; /** * Path to the HTTPS key */ keyPath?: string; /** * Path to the HTTPS cert */ certPath?: string; /** * Path to the HTTPS PFX cert */ pfxPath?: string; /** * If true, when serve is initialized and a dev certificate doesn't already exist and hasn't been * specified, attempt to generate one and trust it automatically. * * defaults to false */ tryCreateDevCertificate?: boolean; } /** * @remarks * If the GCB-serve schema is updated, this schema MUST also be updated. The spfx-serve.schema.json is * the serve.schema.json file with the spfx-specific properties included. The merge is simple, but * must be done manually whenever the serve.schema.json file in GCB is changed. * * @internal */ export interface ISpfxServeTaskConfig extends IServeTaskConfig { serveConfigurations?: { default: ISpfxServeSessionConfiguration; [id: string]: ISpfxServeSessionConfiguration; }; } /** * Describes the interface for serve.json config files in SPFx projects. * * @internal */ export interface ISpfxServe extends ISpfxServeTaskConfig { $schema: string; } /** * @internal */ export interface ISpfxServeSessionConfiguration { /** * The fully-qualified URL of the page to launch */ pageUrl: string; /** * An optional list of custom actions to provide as query parameters to the page. The key of this * object must be the ID of the custom action component. */ customActions?: { [id: string]: ICustomActionConfiguration; }; /** * An optional list of field customizers to provide as query parameters to the page. The key of this * object must be the field ID the customizer applies to. */ fieldCustomizers?: { [fieldName: string]: IFieldCustomizerConfiguration; }; /** * An optional list of form customizers to provide as query parameters to the page. The key of this * object must be the ID of the form component. */ formCustomizer?: IFormCustomizerConfiguration; } /** * @internal */ export interface ICustomActionConfiguration { /** * The type of custom action, use "ClientSideExtension.ApplicationCustomizer" for the Application Customizer * extension. */ location: 'ClientSideExtension.ApplicationCustomizer' | 'ClientSideExtension.ListViewCommandSet.ContextMenu' | 'ClientSideExtension.ListViewCommandSet.CommandBar' | 'ClientSideExtension.ListViewCommandSet' | 'ClientSideExtension.SearchQueryModifier'; properties?: unknown; } /** * @internal */ export interface IFieldCustomizerConfiguration { /** * The ID of the field customizer component. */ id: string; properties?: unknown; } /** * @internal * * @remarks this interface is used to construct query string for List Form page. * The service (server-side) expects parameters in PascalCase. * That's why we are using PascalCase here instead of camelCase. */ export interface IFormCustomizerConfiguration { componentId: string; /** * Form Display Mode. * See {@link @microsoft/sp-core-library#FormDisplayMode} for more information. */ PageType: 4 | 6 | 8; /** * Server relative URL to the current folder of the list. */ RootFolder: string; /** * The ID of the content type for New form. */ ContentTypeID?: string; /** * The ID of the item for Edit/Display forms. */ ID?: number; /** * Component properties */ properties?: unknown; } //# sourceMappingURL=serve.d.ts.map