You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README.md
+7-5
Original file line number
Diff line number
Diff line change
@@ -2,6 +2,8 @@
2
2
3
3
Run it with `npm install` and `npm run dev-server`.
4
4
5
+
[Watch the solution walkthrough here](https://www.youtube.com/watch?v=pA_lq7eeGlg)
6
+
5
7
## How it works
6
8
7
9
### Creating a data type
@@ -11,20 +13,20 @@ Much like the Hackathon, the Editor creates a new post type and define the field
11
13
The "fields" in this prototype are limited to the content areas.
12
14
13
15
When you select a Group block, a new inspector control ("Content area") is added to the sidebar,
14
-
where you can bind the contents to a specific part of the post object.
16
+
where you can bind the contents to a specific part of the post object:
15
17
16
18
-`post_content` binds to the `post_content` attribute.
17
19
- Any other value binds to the post meta fields.
18
20
19
21
### Entering data
20
22
21
-
The data type template and displayed in the Editor. User enters content in the group blocks that were added.
23
+
The data type template is displayed in the Editor. User enters content in the content area blocks that were added.
22
24
23
-
Upon clicking "Save", the back-end will intercept the post, extract the bound Group's contents and
24
-
route them to the appropriate places.
25
+
Upon clicking "Save", the back-end will intercept the post, extract the blocks from the content areas and
26
+
save them to the appropriate places (e.g., `post_content` and post meta fields.)
25
27
26
28
### Displaying data
27
29
28
30
The `post_content` is not intercepted, and the stored content is displayed.
29
31
30
-
The plugin creates a block variation for each post meta field, and also exposes a block that renders the data type template.
32
+
The plugin creates a block variation for each post meta field, and also exposes a block that renders the data type template from the current Query Loop context.
0 commit comments