块编辑器开发文档

使用 Gutenberg 数据创建您的第一个应用

💡 云策文档标注

概述

本教程旨在帮助开发者熟悉 Gutenberg 数据层,通过构建一个简单的 React 应用来管理 WordPress 页面,最终应用示例可在 block-development-examples 仓库中查看。

关键要点

  • 教程引导构建一个基于 Gutenberg 数据层的 React 应用,用于管理 WordPress 页面。
  • 应用开发步骤包括:设置环境、构建页面列表、编辑表单、创建页面表单和添加删除按钮。
  • 面向 WordPress 开发者,强调实践操作和代码示例,以提升对 Gutenberg 数据 API 的理解。

📄 原文内容

This tutorial aims to get you comfortable with the Gutenberg data layer. It guides you through building a simple React application that enables the user to manage their WordPress pages. The finished app will look like this:

Open demo in WordPress Playground

You may review the finished app in the block-development-examples repository.

Table of Contents

  1. Setup
  2. Building a basic list of pages
  3. Building an edit form
  4. Building a create page form
  5. Adding a delete button