Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Full Site Editor: Spike for cost (only) using Editor Provider and creating a new Editor Instance [5] #33514

Closed
gwwar opened this issue May 31, 2019 · 3 comments

Comments

@gwwar
Copy link
Contributor

gwwar commented May 31, 2019

Let's do a timeboxed investigation for a ballpark estimate of what costs are for implementing a new editor instance using two editor providers as noted in #32944 (comment)

We're aiming to figure out the order of magnitude of difficulty out of this task, and as part of that, an idea of any known blockers we have currently. It doesn't need to be perfect, this gives us an initial baseline of work required here.

Our goals are to answer:

  • Is it possible to implement this now, using Gutenberg packages?
  • If not what work is required?
  • If so, what does this cost to implement, and what do ongoing costs look like? Is it reasonable to maintain.
  • If costs are unreasonable, are there any contributions we can make to lessen this?

As @mtias noted:

  • Create your own editor that represents the page title as a block (is not saved in post_content) and the content is passed to another inner block with its own editor provider. (Inspiration).

To handle this you'll need a custom template supplied to your root provider that has a page title and content blocks. I'd start with a locked template so that ordering cannot be changed (title cannot go under content).

See also paAmJe-p3-p2 for further explanation

@gwwar gwwar changed the title Full Site Editor: Spike for cost (only) using Editor Provider and creating a new Editor Instance Full Site Editor: Spike for cost (only) using Editor Provider and creating a new Editor Instance [5] Jun 3, 2019
@dmsnell
Copy link
Member

dmsnell commented Jun 4, 2019

Did a little playing in https://codesandbox.io/s/angry-bhaskara-r3zrc

From what I can see it looks like this route is the intended way to solve our dilemma but it may take someone more knowledgable than I to figure out how to do it.

My current perspective is that we have two approaches:

  • clone the existing EditorProvider at the risk of being a hard-to-maintain fork of the official one and have all the bells and whistles provided for us
  • start from scratch or from the BlockEditorProvider and get essentially nothing premade. this seems like it would practical mean rebuilding EditorProvider as I'm not sure what we wouldn't need from EditorProvider

@gwwar
Copy link
Contributor Author

gwwar commented Jun 4, 2019

Sounds very early still then. I would recommend working with the community on this one than attempting to maintain a fork.

@apeatling
Copy link
Member

Since we're not going to be looking at this in further iterations, I'm going to close.

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

No branches or pull requests

3 participants