From 4bc53938a29ce9ae3c3536d2bcd271d6ab8f5c45 Mon Sep 17 00:00:00 2001 From: Rene Pot Date: Tue, 16 Jan 2024 16:21:49 +0100 Subject: [PATCH 1/4] docs: make markdown valid --- docs/components/Plugin.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/components/Plugin.md b/docs/components/Plugin.md index e8ea7f52..1b1a243f 100644 --- a/docs/components/Plugin.md +++ b/docs/components/Plugin.md @@ -29,7 +29,7 @@ const MyApp = () => ( ## Basic Usage (Using properties from the parent app) -You must build your plugin with the app-platform. If you have done this, your entry component will be passed the props from the parent app. From the example above, the properties `numberToPass` and `callbackToPass` will be available in the build plugin (when it is rendered with a component). +You must build your plugin with the app-platform. If you have done this, your entry component will be passed the props from the parent app. From the example above, the properties `numberToPass` and `callbackToPass` will be available in the build plugin (when it is rendered with a `` component). ```jsx // your plugin entry point (the plugin itself) @@ -60,8 +60,8 @@ const MyPlugin = (propsFromParent) => { ## Plugin Props (custom props) -You can specify pass any other props on the component and these will be passed down to the plugin (provided it was built with app-platform). When props are updated, they will be passed back down to the plugin. This mimics the behaviour of a normal React component, and hence you should provide stable references as needed to prevent rerendering. +You can specify pass any other props on the `` component and these will be passed down to the plugin (provided it was built with app-platform). When props are updated, they will be passed back down to the plugin. This mimics the behaviour of a normal React component, and hence you should provide stable references as needed to prevent rerendering. ## Extended example -See these links for an extended example of how component can be used within an [app](https://github.com/tomzemp/workingplugin/blob/plugin-wrapper-in-platform/src/App.js) and consumed within the [plugin](https://github.com/tomzemp/workingplugin/blob/plugin-wrapper-in-platform/src/Plugin.js). +See these links for an extended example of how `` component can be used within an [app](https://github.com/tomzemp/workingplugin/blob/plugin-wrapper-in-platform/src/App.js) and consumed within the [plugin](https://github.com/tomzemp/workingplugin/blob/plugin-wrapper-in-platform/src/Plugin.js). From da402e1c1f9ea5add1e0a46d6114cc7e3aa43b0f Mon Sep 17 00:00:00 2001 From: Rene Pot Date: Wed, 20 Mar 2024 14:48:26 +0100 Subject: [PATCH 2/4] docs: fix note for developer portal --- docs/components/Plugin.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/components/Plugin.md b/docs/components/Plugin.md index 1b1a243f..41cd3a8b 100644 --- a/docs/components/Plugin.md +++ b/docs/components/Plugin.md @@ -1,6 +1,8 @@ # Plugin Component -_NOTE:_ This component is experimental and is available for import from `@dhis2/app-runtime/experimental`. The api for this component is not guaranteed to be stable. +:::info Experminental +This component is experimental and is available for import from `@dhis2/app-runtime/experimental`. The api for this component is not guaranteed to be stable. +::: A wrapper that creates an iframe for a specified plugin and establishes a two-way communication channel with said plugin, allowing you to pass props (including callbacks between an app and a plugin). Note that the plugin must be built using the app-platform with entryPoints.plugin specified in the d2.config.js file. From 42e9167f84d9eaac2eb17c7ed65270bd12ffc885 Mon Sep 17 00:00:00 2001 From: Rene Pot Date: Wed, 20 Mar 2024 14:56:48 +0100 Subject: [PATCH 3/4] docs: fix formatting --- docs/components/Plugin.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/components/Plugin.md b/docs/components/Plugin.md index 41cd3a8b..02a33c29 100644 --- a/docs/components/Plugin.md +++ b/docs/components/Plugin.md @@ -1,6 +1,6 @@ # Plugin Component -:::info Experminental +:::info Experminental This component is experimental and is available for import from `@dhis2/app-runtime/experimental`. The api for this component is not guaranteed to be stable. ::: From 4e893227280ddf9788ad821294f6df2c469979cc Mon Sep 17 00:00:00 2001 From: Rene Pot Date: Wed, 20 Mar 2024 15:06:52 +0100 Subject: [PATCH 4/4] docs: fix typo --- docs/components/Plugin.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/components/Plugin.md b/docs/components/Plugin.md index 02a33c29..bf5ad8d0 100644 --- a/docs/components/Plugin.md +++ b/docs/components/Plugin.md @@ -1,6 +1,6 @@ # Plugin Component -:::info Experminental +:::info Experimental This component is experimental and is available for import from `@dhis2/app-runtime/experimental`. The api for this component is not guaranteed to be stable. :::