serlo / frontend

Next.js app that serves serlo.org
https://serlo.org
Apache License 2.0
39 stars 10 forks source link

editor: Expose upload of ImageConfig in Editor API #3866

Closed kulla closed 2 weeks ago

kulla commented 4 months ago

Problem which needs to be solved

In the Moodle plugin we want to use the image plugin with a specific configuration so that the files are uploaded to Moodle.

Solution

  1. Add ImageConfig to createBasicPlugins() + PluginsConfig -> When the upload-function is defined add the image plugin as well.
  2. Move validate function into the editor
  3. Make the validate function the default function which does not need to be specified.
  4. Document the solution in the README with a note that the API might change in the future.