Skip to content

Feature request: Possibility to render multiple editors on a page #23

Description

@JeroenReumkens

If I understand the code correctly, it's currently only possible to render one editor on the page if you're using lazy/hydrate.
Would be great if we could pass a selector to these functions, plus unique workspaces to each of them.

Something like this would already be sufficient I think:

const el = document.getElementById('my-editor');
const workspace = new Workspace(...);

hydrate({
  element: el,
  workspace
});

Why I want this?

I'm running my own course platform, and on these pages there's potentially multiple exercises, each running their own playground.

--

Thanks for making this library! So far it looks super useful. I'm already trying to implement it in my platform, although I'm not sure if that's a wise decision while it is still in early development 😁

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions