WordPress Developer Ukraine, Kyiv
Extend the WordPress REST API with register_rest_field()

Extend the WordPress REST API with register_rest_field()

Extend the WordPress REST API with register_rest_field() The REST API returns a fixed set of fields for every post: id, title, content, status and so on. Data that a theme or plugin keeps in post meta, in terms or in its own tables is not there. With register_rest_field() you add it to the existing response,…
Gutenberg: Troubleshooting “Updating Failed” Errors

Gutenberg: Troubleshooting “Updating Failed” Errors

Gutenberg: troubleshooting “Updating failed” errors The Gutenberg editor saves posts through the REST API. When saving fails, the editor shows a generic “Updating failed” banner that gives no clue about the actual cause. Here are the five most common reasons and how to fix each one.
Using the WordPress REST API as a Headless CMS Backend

Using the WordPress REST API as a Headless CMS Backend

Use the WordPress REST API as a headless CMS backend In a headless setup WordPress is only the place where content is written and stored. The site that visitors see is a separate application, for example in React or Vue, that reads the content through the REST API. Editors keep the familiar admin, and the…