-
Notifications
You must be signed in to change notification settings - Fork 4.6k
Open
Labels
[Feature] Templates APIRelated to API powering block template functionality in the Site EditorRelated to API powering block template functionality in the Site Editor[Type] BugAn existing feature does not function as intendedAn existing feature does not function as intended
Description
Description
Block templates are connected to specific URL paths and are not updated if the original post's post_name is updated. We might want to consider linking to the short URL (canonical) as a reference instead.
Step-by-step reproduction instructions
- Create a post "Test Post A" and publish. Observe that with permalinks enabled, the
post_nameistest-post-a. - Create a custom block template for the previous post and add some additional blocks to the template to help verify this custom template is loaded on the front end. After saving the template, view the post on the frontend and it should be using the custom template.
- Edit the "Test Post A" post and change the
post_namevalue to something different. - View the post on the frontend and you'll see that it is no longer using the custom template that was created.
Screenshots, screen recording, code snippet
No response
Environment info
- WordPress: 6.0.2
- Gutenberg: 13.9.0
Please confirm that you have searched existing issues in the repo.
Yes
Please confirm that you have tested with all plugins deactivated except Gutenberg.
Yes
Metadata
Metadata
Assignees
Labels
[Feature] Templates APIRelated to API powering block template functionality in the Site EditorRelated to API powering block template functionality in the Site Editor[Type] BugAn existing feature does not function as intendedAn existing feature does not function as intended