Created
January 30, 2025 15:29
-
-
Save sitefinitySDK/53b0b8534750fa2d8118a1432456b630 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { WidgetRegistry, initRegistry, defaultWidgetRegistry } from '@progress/sitefinity-nextjs-sdk'; | |
import { SitefinityData } from './widgets/sitefinity-data/sitefinity-data'; | |
import { SitefinityDataEntity } from './widgets/sitefinity-data/sitefinity-data.entity'; | |
const customWidgetRegistry: WidgetRegistry = { | |
widgets: { | |
'SitefinityData': { | |
componentType: SitefinityData, // registration of the widget | |
entity: SitefinityDataEntity, // registration of the designer | |
ssr: true, // whether this is a server rendered or client rendered component | |
editorMetadata: { | |
Title: 'Sitefinity data' | |
} | |
} | |
} | |
}; | |
Object.keys(defaultWidgetRegistry.widgets).forEach((key) => { | |
customWidgetRegistry.widgets[key] = defaultWidgetRegistry.widgets[key]; | |
}); | |
export const widgetRegistry: WidgetRegistry = initRegistry(customWidgetRegistry); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment