[wp-trac] [WordPress Trac] #62574: Move default template types and template part areas to REST API
WordPress Trac
noreply at wordpress.org
Thu Feb 13 21:12:41 UTC 2025
#62574: Move default template types and template part areas to REST API
---------------------------------------+-----------------------
Reporter: gigitux | Owner: gigitux
Type: enhancement | Status: assigned
Priority: normal | Milestone: 6.8
Component: Editor | Version:
Severity: normal | Resolution:
Keywords: has-patch gutenberg-merge | Focuses:
---------------------------------------+-----------------------
Comment (by peterwilsoncc):
Replying to [comment:12 Mamaduka]:
> The REST API index is the only option for `read-only` settings until
#48885 is resolved.
I think it best to resolve this prior to moving these to the REST API, or
to make the data available on the templates endpoint, theme endpoint or
similar.
> > The associated PR doesn't make the fields available to the endpoint by
default which is a little counter intuitive. In order to access them, a
developer must include the usually optional ?_fields parameter.
>
> IIRC, if you request without fields, all fields are returned, including
new fields proposed in this PR.
I've double checked using the
[https://playground.wordpress.net/?url=%3Frest_route%3D%2F&core-
pr=7895#{%22$schema%22:%22https://playground.wordpress.net/blueprint-
schema.json%22,%22login%22:true,%22features%22:{%22networking%22:true}} WP
Playground for the attached PR] and if you search for the relevant strings
for the default rest endpoint, you'll see that they are missing.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/62574#comment:13>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list