Ưu đãi trong tuần: Nhập mã UD50 giảm 50k cho đơn từ 300k!
Trang chủ
Menu

Gutenberg Blocks for WordPress and React Developers

Gutenberg Blocks dành cho WordPress và React Developers

Gutenberg Blocks dành cho WordPress và React Developers

Áp dụng kiến thức ReactJS và Redux để tạo Gutenberg Blocks và Plugins phức tạp từ đầu

4.4
(944 đánh giá)
6,391 học viên
Giảng viên
Ali Alaa
Phụ đề Việt chất lượng cao Phụ đề tiếng Anh Bán chạy Đánh giá cao
50.000đ 349.000đ -86%
✓ Xem giỏ hàng và thanh toán
Bao gồm phụ đề tiếng Việt, tiếng Anh
16.0 giờ video
236 bài giảng
Truy cập vĩnh viễn
Học trên mọi thiết bị
Cập nhật: 29/05/2026

Bạn sẽ học được gì

Tìm hiểu về nguyên tắc thiết kế cho block editor
Khám phá cách block editor lưu bài viết vào database và cách giao diện editor được xây dựng
Hướng dẫn sử dụng wp-scripts để transpile ES6 và JSX, biên dịch SASS thành CSS, đóng gói và tối ưu file JS/CSS
Tích hợp ESLint, Prettier, Stylelint và Husky vào dự án để cải thiện quy trình làm việc
Tạo custom Gutenberg block mới từ đầu
Tùy chỉnh tính năng block editor trong WordPress theme
Khám phá mọi khía cạnh cần biết để tạo Gutenberg block phức tạp
Tạo nested block (block chứa các block khác bên trong)
Sử dụng thư viện React bên thứ ba để tạo tính năng phức tạp
Tìm hiểu về xử lý deprecated blocks
Hướng dẫn chuyển đổi custom block thành block khác
Tạo dynamic block
Khám phá cách sử dụng data stores có sẵn trong blocks
Hướng dẫn tạo data stores riêng để chia sẻ dữ liệu giữa các blocks
Tìm hiểu các cách quản lý meta fields trong block editor
Hướng dẫn tạo custom sidebar trong block editor và quản lý meta fields bên trong
Hướng dẫn mở rộng sidebar có sẵn của block editor
Tìm hiểu về các tính năng như patterns, context, formatting API và templates
Thay đổi hành vi của block có sẵn bằng JavaScript & PHP filters
Quốc tế hóa blocks bằng cách tạo và tải file dịch

Yêu cầu

Bạn cần có kiến thức cơ bản về HTML, CSS (SASS), Javascript và PHP
Bạn cần có kinh nghiệm phát triển WordPress
Bạn cần nắm các khái niệm cơ bản về ReactJS
Có kiến thức về Redux là một lợi thế
Bất kỳ code editor nào bạn quen thuộc, tôi sẽ dùng VS Code trong khóa học này
Local server như MAMP, WAMP, XAMPP, Laragon hoặc phần mềm khác bạn biết. Tôi sẽ dùng MAMP xuyên suốt khóa học
Cài đặt NodeJS và NPM hoặc Yarn trên máy tính

Đối tượng phù hợp

WordPress theme/plugin developers đã biết ReactJS và muốn tạo Gutenberg blocks từ đầu
Bất kỳ ai có kinh nghiệm WordPress và ReactJS muốn hiểu mọi thứ về Gutenberg editor

Nội dung khóa học

10 phần • 114 bài giảng
1 Trước khi xem khóa học
2 Cài đặt WordPress Theme mẫu
3 Giao diện Block Editor
4 Giao diện Block & Nguyên tắc Thiết kế
5 Cách Block Editor lưu bài viết vào Database
6 Cách Visual Editor được tái tạo từ HTML thuần
7 Giới thiệu ngắn về Data Stores kiểu Redux trong Block Editor
8 Post State Array trong thực tế
1 Tạo WordPress Plugin mới
2 Đăng ký Block đầu tiên
3 Trả về React Components trong Edit & Save Functions
4 Lưu ý quan trọng
5 Biên dịch ESNext thành ES5 với wp-scripts
6 Biên dịch & Tải SASS Files
7 Tạo Block với @wordpress/create-block
8 Cấu hình ESLint & Prettier cho JavaScript Files
9 Cấu hình Stylelint cho SCSS Files
10 Thêm Pre-commit Git Hook với Husky
1 Thêm Custom Styles vào Block Editor
2 Thêm hỗ trợ Align Wide và Align Full
3 Thêm Custom Colour Pallets
4 Thêm Custom Font Sizes
5 Custom Sizing & Custom Units
1 Tạo bản sao mới từ Boilerplate đúng cách
2 Chỉnh sửa Metadata của Boilerplate
3 Tùy chỉnh Icon của Block
4 RichText Component
5 Thêm tùy chọn trong Block Toolbar sử dụng BlockControls
6 AlignmentToolbar Component
7 Thêm tùy chọn trong Sidebar sử dụng InspectorControls
8 Thêm tùy chọn thay đổi Background và Text Colours
9 Sử dụng withColors Higher Order Component
10 Thay đổi Background và Text Colours sử dụng Block Supports
11 Thêm tùy chọn thay đổi Padding của Block
12 Thêm tùy chọn bật/tắt Box Shadow
13 Thêm hỗ trợ cho các tùy chọn Style khác nhau
14 Ví dụ & Biến thể
15 Chuyển đổi Blocks thành Blocks khác
16 Thêm Deprecated Versions cho Block của chúng ta
17 Thêm Deprecated Versions cho Block của chúng ta (Phần 2)
1 Tổng quan về Block
2 Khởi tạo Plugin mới cho Block của chúng ta
3 Chỉnh sửa Metadata của Boilerplate
4 Sử dụng InnerBlocks để tạo Nested Block
5 Đăng ký Team Member Block
6 Tạo edit và save functions cho name và bio
7 Thêm templates cho team members
8 Thêm tùy chọn thay đổi số lượng columns
9 Styling Front-end của Block
10 Thêm Editor Styles cho Block của chúng ta
11 Giới thiệu ImagePlaceholder Component
12 Lưu trữ & Hiển thị Team Member Image
13 Xử lý chèn Image từ External URL
14 Hiển thị lỗi liên quan đến Image
15 Hiển thị Image trong Save Function (Front-end)
16 Blob URL Edge Case & Tối ưu bộ nhớ
17 Thay thế Image với Toolbar Option
18 Xóa Image với Toolbar Option
19 Thêm Sidebar Option để chỉnh sửa Alt Text của Image
20 Thêm tùy chọn thay đổi Image Size
21 Tập trung vào Name Input sau khi chọn Image
22 Thêm Alignment Options cho Team Members Block
23 Thêm & Hiển thị Attribute cho Social Links
24 Styling Social Links cho Editor Page
25 Selected Link State & Styling
26 Thêm Items mới vào Social Links
27 Save Function Markup cho Social Links
28 Trích xuất Social Links Array từ HTML để cải thiện hiệu suất
29 Thêm Markup cho Edit Link Form
30 Chỉnh sửa Social Media Links & Icons
31 Xóa Social Links
32 Làm cho Social Links có thể sắp xếp (Phần 1)
33 Làm cho Social Links có thể sắp xếp (Phần 2)
34 Thêm Example cho Block Preview
35 Thêm Transformations cho Team Members Block
1 Giới thiệu về Dynamic Blocks
2 Khởi tạo Latest Posts Block của chúng ta
3 Chỉnh sửa Metadata của Boilerplate
4 Hiển thị Dynamic Content trong Front-end
5 Hiển thị Latest Posts trong Front-end sử dụng PHP
6 Chuẩn bị Data cho Editor Loop
7 Hiển thị Latest Posts trong Editor
8 Styling Posts trong Editor và Front-end
9 Thêm tùy chọn cho Number of Posts và Featured Image
10 Thêm tùy chọn thay đổi Order của Posts
11 Lọc Posts theo Categories
1 Lưu ý nhanh!
2 Tạo Plugin Boilerplate mới cho Block Editor
3 Tích hợp wp-scripts vào Boilerplate của chúng ta
1 Core Data Stores
2 Sử dụng Data được lưu trữ bên trong Blocks
3 Tổng quan về Todos Store
4 Đăng ký Custom Store
5 Điền dữ liệu Store từ external API
6 Xử lý lỗi API
7 Hiển thị Todos trong Todo List Block
8 Thêm Form để thêm Todos mới
9 Sử dụng API để thêm Todos mới
10 Sử dụng API để Toggle Todos
11 Tạo Todo List Info Block
1 Cách quản lý Metadata cũ bằng PHP
2 Thao tác Meta Fields sử dụng Data Stores
3 Quản lý Meta Fields sử dụng Blocks
4 Thêm Custom Sidebar sử dụng Plugins
5 Tùy chỉnh Editor UI có sẵn
6 Thêm tùy chọn chỉnh sửa Meta Fields trong Sidebar
1 Truyền Attributes từ Parent sang Child sử dụng Context
2 Thêm Predefined Templates cho Post Types
3 Thêm Predefined Block Patterns
4 Sử dụng Formatting API để thêm Text Formats mới
5 Thay đổi hành vi có sẵn với PHP Filters
6 Thay đổi hành vi có sẵn với JavaScript Filters
7 Quốc tế hóa - Tạo & Tải Translation Files
8 BÀI GIẢNG BỔ SUNG

Giới thiệu khóa học

Recently WordPress decided to change their old WYSIWYG editor into a new ReactJS based block editor known as 'Gutenberg'. Gutenberg also known as the block editor is based on blocks. So your post will be composed of some blocks and each block will have a purpose. You can have a block that displays a button or an image or some text and so on. 

In this course you will learn everything you need to know in order to create custom blocks for the block editor. We will start by a simple block and then we will create some more complex blocks.

In order to gain the most out of this course you need to have WordPress theme/plugin development knowledge. Javascript knowledge is required for this course. You should be familiar with basic JavaScript concepts and preferably the recent ES6+ versions. ReactJS knowledge is also required for this course. So concepts like component state, hooks and basic react concepts should not be new to you. Also advanced concepts like higher order component knowledge would be ideal however it will be discussed briefly in the course. Redux knowledge is also ideal. Not all blocks will require using redux, however in some blocks we will use redux heavily. So it would be ideal if you are familiar with redux concepts like stores, actions, reducers and so on.

The course content will go as follows:

  • First and before any coding we will discuss some design guidelines that you should follow when designing a block.

  • We will take a look on how your Gutenberg post is saved in your database and what happens behind the scenes in order to construct your ReactJS based UI from the content saved in the database.

  • In Section 2, we will create a WordPress plugin. Inside this plugin we will register out first Gutenberg block. We will also use a tool provided by WordPress called wp-scripts in order to process JS and CSS files in this plugin. We will also integrate tools like ESLint, Prettier, Stylelint and Husky for an improved development workflow.

  • In section 3, we will take a quick look on some stuff that you can do in your WordPress theme that will allow you to modify/add some features in the block editor.

  • In section 4 we will create a simple block. However in this simple block we will learn a lot about what we can do in a block.

  • In section 5 we will use our knowledge to create a more complex block with some advanced features. These features include how to add blocks inside of other blocks, how to handle images and many more.

  • Section 6 will be about creating dynamic blocks. So blocks can be static or in other words only generate some static HTML. But also they can be dynamic for example they can fetch something from the database.

  • Section 7 will discover more about the redux-like data stores in the block editor. We will see how to use the existing data stores and also create our own store.

  • Section 8 we will see different ways that we can follow in order to manage metadata in Gutenberg. We will manage metadata using a block. And we will also learn how to create a custom sidebar plugin and manage metadata in this sidebar.

  • In the final section we are going to discuss various topics like: context, patterns, templates, formatting API, filters and internationalization.

 

Khóa học liên quan

Khám phá thêm các khoá học cùng chủ đề

Hiển thị tất cả khoá học Javascript
Hiển thị tất cả khoá học React
Hiển thị tất cả khoá học Web Development
Hiển thị tất cả khoá học Wordpress Development
Zalo
Tôi có thể tư vấn khoá học cho bạn 😊