Wordpress/tests/qunit
TimothyBlynJacobs 2b42ac5a12 REST API: Only register one block renderer route.
Every block has a different set of attributes. These attributes are specified as a JSON Schema object. Previously, every block registered its own block renderer route using its attributes for the schema. This allowed for the attributes to be validated using the built in endpoint validation rules. It had the unfortunate side effect, however, of creating a large number of nearly identical REST API routes, one for each dynamic block. Each registered route has a performance impact. As the number of server side blocks goes up, this becomes more and more of an issue.

Now, we register a single block renderer route and dynamically validate the attributes based on the selected block.

Fixes #48079.
Props gziolo, TimothyBlynJacobs.


git-svn-id: https://develop.svn.wordpress.org/trunk@48069 602fd350-edb4-49c9-b593-d223f7449a82
2020-06-17 03:20:02 +00:00
..
fixtures REST API: Only register one block renderer route. 2020-06-17 03:20:02 +00:00
wp-admin/js
wp-includes/js
.jshintrc
index.html