foundation-header.configure
Home > @genesislcap/foundation-header > configure
configure() function
A function that allows configuring the header micro-frontend with name and templateOptions.
Signature:
export declare function configure(config: Partial<HeaderConfig>): Promise<typeof import("../main").Navigation>;
Parameters
|
Parameter |
Type |
Description |
|---|---|---|
|
config |
Partial<HeaderConfig> |
A partial HeaderConfig. |
Returns:
Promise<typeof import("../main").Navigation>
Remarks
Configure the Header micro frontend for host app integration.
Example
Providing template options to align to your host application.
const { configure } = await import('@genesislcap/foundation-header/config'); // < import from the subpath
return configure({
name: `nexus-app-header`,
// These will be merged with the packages `defaultTemplateOptions`. You will need to have these components registered in your application.
templateOptions: {
button: 'nexus-button',
icon: 'nexus-icon-next',
},
});
},