|
1 | | -# CKEditor 5 custom field for Strapi |
| 1 | +# CKEditor 5 - Official Integration for Strapi |
2 | 2 |
|
3 | 3 | <img src="https://user-images.githubusercontent.com/156149/192792402-4bb1e040-6f8c-49be-af90-fd35fd3a4c66.png" alt="CKEditor 5 used inside Strapi. Article form consisting of a title, excerpt text, and content"> |
4 | 4 |
|
5 | | -This package provides a custom field for Strapi that lets you use and configure CKEditor in no time. |
| 5 | +> [!IMPORTANT] |
| 6 | +> Starting from version 1.0.0, the CKEditor 5 custom field plugin is compatible with Strapi 5 and can’t be used in Strapi 4.4+. We decided to maintain integrations for both Strapi versions to ensure that you can still use our custom field before migrating to Strapi 5. Below is the [compatibility table](#compatibility) showing which plugin version should be used with your Strapi version. |
| 7 | +
|
| 8 | +This package provides a custom field for Strapi 5 that lets you use and configure CKEditor in no time. |
6 | 9 |
|
7 | 10 | Custom fields are supported since Strapi 4.4+ and offer powerful API to create highly customizable fields. |
8 | 11 |
|
@@ -33,7 +36,26 @@ With `yarn`: |
33 | 36 | yarn add @ckeditor/strapi-plugin-ckeditor |
34 | 37 | ``` |
35 | 38 |
|
36 | | -Then run build: |
| 39 | +Then, add the Content Security Policy configuration to allow loading CKEditor 5 from https://cdn.ckeditor.com origin, by adding the rule to `config/middlewares.ts` in your Strapi project root: |
| 40 | + |
| 41 | +```js |
| 42 | +export default [ |
| 43 | + // ... |
| 44 | + { |
| 45 | + name: 'strapi::security', |
| 46 | + config: { |
| 47 | + contentSecurityPolicy: { |
| 48 | + useDefaults: true, |
| 49 | + directives: { |
| 50 | + 'script-src': ['https://cdn.ckeditor.com'] |
| 51 | + }, |
| 52 | + }, |
| 53 | + }, |
| 54 | + }, |
| 55 | + // ... |
| 56 | +``` |
| 57 | + |
| 58 | +Finally run build: |
37 | 59 |
|
38 | 60 | ```bash |
39 | 61 | npm run build |
@@ -100,3 +122,42 @@ Rebuild the project and start the server: |
100 | 122 | yarn build |
101 | 123 | yarn develop |
102 | 124 | ``` |
| 125 | + |
| 126 | +## <a id="compatibility"></a>🧩 Compatibility with Strapi versions |
| 127 | + |
| 128 | +Starting from version 1.0.0, the CKEditor 5 custom field plugin is compatible with Strapi 5 and can't be used in Strapi 4.4+. We decided to maintain integrations for both Strapi versions to make sure that you still be able to use our custom field before migrating to Strapi 5. Below, you can find the compatibility table that shows which plugin version should be used with your Strapi version. |
| 129 | + |
| 130 | + <table> |
| 131 | + <thead> |
| 132 | + <tr> |
| 133 | + <th> |
| 134 | + Plugin version |
| 135 | + </th> |
| 136 | + <th> |
| 137 | + Strapi version |
| 138 | + </th> |
| 139 | + </tr> |
| 140 | + </thead> |
| 141 | + <tbody> |
| 142 | + <tr> |
| 143 | + <td> |
| 144 | + 1.x.x |
| 145 | + </td> |
| 146 | + <td> |
| 147 | + ≥ 5.0.0 |
| 148 | + </td> |
| 149 | + </tr> |
| 150 | + <tr> |
| 151 | + <td> |
| 152 | + 0.x.x |
| 153 | + </td> |
| 154 | + <td> |
| 155 | + ≥ 4.4 |
| 156 | + </td> |
| 157 | + </tr> |
| 158 | + </tbody> |
| 159 | +</table> |
| 160 | + |
| 161 | +## <a id="licensing"></a>⚖️ Licensing |
| 162 | + |
| 163 | +The plugin "CKEditor 5 - Official Integration for Strapi" is licensed under MIT. Please note that [CKEditor 5 itself is licensed under GPL v2+](https://ckeditor.com/legal/ckeditor-oss-license/?utm_campaign=strapi-integration&utm_source=ck-github&utm_medium=referral) or a [commercial license](https://ckeditor.com/pricing/?utm_campaign=strapi-integration&utm_source=ck-github&utm_medium=referral). |
0 commit comments