Skip to content

Commit 5de0d1f

Browse files
authored
Update backoffice-entry-point.md
Fixed typos in code examples where the parameter for "extensionRegistry" reads "extensionsRegistry", which is not correct. Also there was an example where it said "extension.unregister" instead of "extensionRegistry.unregister"
1 parent a56ed45 commit 5de0d1f

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

15/umbraco-cms/customizing/extending-overview/extension-types/backoffice-entry-point.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -43,14 +43,14 @@ import type { UmbEntryPointOnInit } from '@umbraco-cms/backoffice/extension-api'
4343
/**
4444
* Perform any initialization logic when the Backoffice starts
4545
*/
46-
export const onInit: UmbEntryPointOnInit = (host, extensionsRegistry) => {
46+
export const onInit: UmbEntryPointOnInit = (host, extensionRegistry) => {
4747
// Your initialization logic here
4848
}
4949

5050
/**
5151
* Perform any cleanup logic when the Backoffice and/or the package is unloaded
5252
*/
53-
export const onUnload: UmbEntryPointOnUnload = (host, extensionsRegistry) => {
53+
export const onUnload: UmbEntryPointOnUnload = (host, extensionRegistry) => {
5454
// Your cleanup logic here
5555
}
5656
```
@@ -78,14 +78,14 @@ const manifest: UmbExtensionManifest = {
7878
}
7979
};
8080

81-
export const onInit: UmbEntryPointOnInit = (host, extensionsRegistry) => {
81+
export const onInit: UmbEntryPointOnInit = (host, extensionRegistry) => {
8282
// Register the extension
8383
extensionRegistry.register(manifest);
8484
}
8585

86-
export const onUnload: UmbEntryPointOnUnload = (host, extensionsRegistry) => {
86+
export const onUnload: UmbEntryPointOnUnload = (host, extensionRegistry) => {
8787
// Unregister the extension (optional)
88-
extension.unregister(manifest);
88+
extensionRegistry.unregister(manifest);
8989
}
9090
```
9191
{% endcode %}
@@ -139,7 +139,7 @@ const manifests: Array<UmbExtensionManifest> = [
139139
...
140140
];
141141

142-
export const onInit: UmbEntryPointOnInit = (host, extensionsRegistry) => {
142+
export const onInit: UmbEntryPointOnInit = (host, extensionRegistry) => {
143143
// Register the extensions
144144
extensionRegistry.registerMany(manifests);
145145
}

0 commit comments

Comments
 (0)