Skip to content

Commit 564f65c

Browse files
Plugin migration updates (#2208)
* Plugin migration updates * Fixing a broken link * Update docusaurus/docs/dev-docs/migration/v4-to-v5/additional-resources/plugins-migration.md * Update docusaurus/docs/dev-docs/migration/v4-to-v5/additional-resources/plugins-migration.md * Update docusaurus/docs/dev-docs/migration/v4-to-v5/additional-resources/plugins-migration.md * Update docusaurus/docs/dev-docs/migration/v4-to-v5/additional-resources/plugins-migration.md * Update docusaurus/docs/dev-docs/migration/v4-to-v5/additional-resources/plugins-migration.md --------- Co-authored-by: Pierre Wizla <pwizla@users.noreply.github.com>
1 parent 67b8e09 commit 564f65c

File tree

1 file changed

+18
-3
lines changed

1 file changed

+18
-3
lines changed

docusaurus/docs/dev-docs/migration/v4-to-v5/additional-resources/plugins-migration.md

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,25 +11,40 @@ tags:
1111

1212
The present page is intended to be used as a short summary of everything to consider if you are a plugin developer upgrading your plugin from Strapi v4 to Strapi 5. The page quickly describes the changes affecting plugins and links to additional resources where necessary.
1313

14+
:::strapi Plugin SDK
15+
Starting with Strapi 5, the platform includes a [Plugin SDK](/dev-docs/plugins/development/plugin-sdk) to help develop and build Strapi plugins. While you are free to use other methods for plugin development, we strongly recommend using the Plugin SDK. As part of the migration process from v4 to Strapi 5, we encourage you to update your plugin to take advantage of the Plugin SDK.
16+
:::
17+
18+
## Recommended steps to migrate a plugin
19+
:::prerequisites
20+
Your Strapi application is already running on the latest v5 minor and patch version. If it's not, follow the [step-by-step guide](/dev-docs/migration/v4-to-v5/step-by-step) to upgrade to Strapi 5.
21+
:::
22+
1423
Upgrading a Strapi v4 plugin to Strapi 5 consists in:
1524

1625
1. Creating a new empty plugin using the [Plugin SDK](/dev-docs/plugins/development/create-a-plugin).
1726
2. Move your Strapi v4 code to the newly created files in the Strapi 5 [plugin structure](/dev-docs/plugins/development/plugin-structure), also considering the changes summarized in this page.
1827

19-
## Back-end changes
28+
Alternatively, you can manually update your Strapi v4 plugin to use the Plugin SDK.
29+
The manual steps include:
30+
1. If your code uses a format other than CommonJS, update the `package.json` file and specify the appropriate exports property.
31+
2. Reorganize your Strapi v4 code to align with the Strapi 5 [plugin structure](/dev-docs/plugins/development/plugin-structure)
32+
33+
### Back-end changes
2034

2135
- The Entity Service API from Strapi v4 is deprecated and Strapi 5 uses the [Document Service API](/dev-docs/api/document-service) instead. A [migration guide](/dev-docs/migration/v4-to-v5/additional-resources/from-entity-service-to-document-service) is available to help you transition to the Document Service API.
2236
- General Strapi v4 to Strapi 5 [breaking changes](/dev-docs/migration/v4-to-v5/breaking-changes) might apply.
2337
- You can use the new [Plugin SDK](/dev-docs/plugins/development/create-a-plugin) to generate plugins and publish them on NPM and/or submit them to the Marketplace.
2438

25-
## Front-end changes
39+
### Front-end changes
2640

2741
- The Design System is upgraded to v2 in Strapi 5:
2842
- 👉 A dedicated migration guide is [available in the Design System documentation](https://design-system-git-main-strapijs.vercel.app/?path=/docs/getting-started-migration-guides-v1-to-v2--docs).
2943
- There are no big visual changes, except for [icons](https://design-system-git-main-strapijs.vercel.app/?path=/docs/foundations-icons-overview--docs).
3044
- General Strapi v4 to Strapi 5 [breaking changes](/dev-docs/migration/v4-to-v5/breaking-changes) might apply.
31-
- The `helper-plugin` is deprecated. A [migration reference](/dev-docs/migration/v4-to-v5/additional-resources/helper-plugin) is available to help you transition away from the `helper-plugin`.
45+
- The `helper-plugin` has been removed. A [migration reference](/dev-docs/migration/v4-to-v5/additional-resources/helper-plugin) is available to help you transition away from the `helper-plugin`.
3246
- Strapi does not alias dependencies any longer. The 4 dependencies that are expected to be used by all client facing code are declared at the project level (`react`, `react-dom`, `styled-components`, and `react-router-dom`). If you do not declare the dependencies that you use (e.g. `axios`), there is a likelihood users could face unforeseen issues with your plugin.
47+
- If you're using the [Plugin SDK](/dev-docs/plugins/development/create-a-plugin), you will need to transition your front-end files to `.jsx` or `.tsx` format.
3348

3449
## Custom providers
3550

0 commit comments

Comments
 (0)