initialize MethodStatic

Initializes Presentation library for the frontend.

Example:

await Presentation.initialize({
  presentation: {
    // specify locale for localizing presentation data, it can be changed afterwards
    activeLocale: IModelApp.localization.getLanguageList()[0],

    schemaContextProvider: MyAppFrontend.getSchemaContext.bind(MyAppFrontend),
  },
  favorites: {
    storage: createFavoritePropertiesStorage(DefaultFavoritePropertiesStorageTypes.UserPreferencesStorage),
  },
});

The method should be called after a call to IModelApp.startup.

initialize(props?: PresentationProps): Promise<void>

Parameter Type Description
props PresentationProps  

Returns - Promise<void>

Defined in

Last Updated: 16 April, 2024