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

Add documentation describing how plugins can add templates #37476

Closed
talldan opened this issue Dec 17, 2021 · 6 comments
Closed

Add documentation describing how plugins can add templates #37476

talldan opened this issue Dec 17, 2021 · 6 comments
Assignees
Labels
[Feature] Templates API Related to API powering block template functionality in the Site Editor [Type] Developer Documentation Documentation for developers

Comments

@talldan
Copy link
Contributor

talldan commented Dec 17, 2021

Related #37401, #36597

What problem does this address?

It was mentioned in #36597 (comment) that plugins can add templates via a filter. Setting some template fields (setting the source to 'plugin', and theme to the plugin slug) helps to indicate where the template came from.

Support for this has since been added to the template list interface.

As mentioned on #37401 the process for plugins adding templates isn't necessarily all that clear as the theme field doesn't seem obvious, but that's hard to change now due to backwards compatibility.

There's a risk if this isn't documented well that plugins will end up using inconsistent techniques for providing templates.

cc @Aljullu @tjcafferkey

What is your proposed solution?

Add some documentation and/or a tutorial for this process

@talldan talldan added [Type] Developer Documentation Documentation for developers [Feature] Templates API Related to API powering block template functionality in the Site Editor labels Dec 17, 2021
@mkaz mkaz self-assigned this Dec 18, 2021
@mkaz mkaz moved this to Todo in WP 5.9 Documentation Dec 18, 2021
@mkaz mkaz removed their assignment Dec 18, 2021
@Mamaduka
Copy link
Member

Mamaduka commented Jan 5, 2022

I am removing this issue from the 5.9 board. It's tracked in the documentation project.

@mburridge
Copy link
Contributor

Add some documentation and/or a tutorial for this process

Where do you think this documentation / tutorial should live?

@talldan
Copy link
Contributor Author

talldan commented Apr 20, 2023

Probably in the plugin handbook.

@mburridge
Copy link
Contributor

Thanks @talldan. In that case, if it's not something for the Block Editor Handbook, do you think we should close this and open a new issue over in Documentation-Issue-Tracker?

@annezazu
Copy link
Contributor

@ndiego noting for you as you work on the block editor handbook overhaul. Can you follow up on this/ensure it's in the right place?

@ndiego ndiego assigned ndiego and unassigned mburridge Oct 27, 2023
@talldan
Copy link
Contributor Author

talldan commented Jul 26, 2024

Closing this in favour of #61577, which should add a much easier API and docs.

@talldan talldan closed this as not planned Won't fix, can't repro, duplicate, stale Jul 26, 2024
@github-project-automation github-project-automation bot moved this from Todo to Done in WP 5.9 Documentation Jul 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Templates API Related to API powering block template functionality in the Site Editor [Type] Developer Documentation Documentation for developers
Projects
Status: Done
Development

No branches or pull requests

7 participants