You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docusaurus/docs/dev-docs/migration/v4-to-v5/additional-resources/plugins-migration.md
+18-3Lines changed: 18 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,25 +11,40 @@ tags:
11
11
12
12
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.
13
13
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
+
14
23
Upgrading a Strapi v4 plugin to Strapi 5 consists in:
15
24
16
25
1. Creating a new empty plugin using the [Plugin SDK](/dev-docs/plugins/development/create-a-plugin).
17
26
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.
18
27
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
20
34
21
35
- 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.
22
36
- General Strapi v4 to Strapi 5 [breaking changes](/dev-docs/migration/v4-to-v5/breaking-changes) might apply.
23
37
- 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.
24
38
25
-
## Front-end changes
39
+
###Front-end changes
26
40
27
41
- The Design System is upgraded to v2 in Strapi 5:
28
42
- 👉 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).
29
43
- There are no big visual changes, except for [icons](https://design-system-git-main-strapijs.vercel.app/?path=/docs/foundations-icons-overview--docs).
30
44
- 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`.
32
46
- 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.
0 commit comments