Strapi plugin image-api
This is a plugin for strapi 3.0.x
It helps you to search for images on Unsplash and import to your media library and insert to your Rich Text
content with appropriate attribution.
** This plugin currently isn't compatible with other plugins that override your wysiwyg editor but it works fine if you override the wysiwyg editor yourself by creating file at /extensions/content-manager/admin/src/components
**
Screenshots
Installation
-
Register an Unsplash account here
-
Create an app on Unsplash, take a note on your
app name
and yourAccess Key
, it will be used later. Note: there would be a limit of 50 requests per hour for a demo app -
With yarn:
yarn add strapi-plugin-image-api
With npm:
npm install strapi-plugin-image-api
-
Generate a config file at the path
/extensions/image-api/config/config.json
with below content -
If you haven't installed any plugins that override your wysiysg editor like this one
You can create a file under this path
/extensions/content-manager/admin/src/components/WysiwygWithErrors/index.js
with the content hereOr the other option is the plugin exposed a
ImageApiPanel
component which takes 2 propseditor
- object of{ name, value }
props of your wysiysg editoronEditorChange
- the onChange event props that strapi passed to your wysiysg editor