[wp-trac] [WordPress Trac] #48828: wp rest api renders loads and executes content for all pages when gutenberg retrieves a list of pages for the page parent select
WordPress Trac
noreply at wordpress.org
Thu Nov 28 15:20:53 UTC 2019
#48828: wp rest api renders loads and executes content for all pages when gutenberg
retrieves a list of pages for the page parent select
--------------------------+-----------------------------
Reporter: hobzhobz | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: REST API | Version:
Severity: normal | Keywords:
Focuses: |
--------------------------+-----------------------------
Latest version of wordpress.
When editing a page in gutenberg there is a select-element where you can
select the parent of this page.
The select is populated using the wp rest api / ajax.
The problem is that each pages content is rendered. This means that also
shortcodes in pages are executed.
So lets say that you have 100 pages and each page has a shortcode that
takes 1 second, it would take 100 seconds to load ...
Gutenberg does not need the content of the pages to populate the select,
all it needs imho is ID, Title, Menu Order, Parent
Another problem with this is that if one shortcode has faulty code in it,
it could make the rest api crash and gutenberg would be unable to populate
the dropdown.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/48828>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list