Skip to content

Commit

Permalink
Reword the version2
Browse files Browse the repository at this point in the history
  • Loading branch information
youknowriad committed Dec 10, 2020
1 parent be1a439 commit f7ab9dc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/designers-developers/developers/block-api/versions.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ This document lists the changes made between the different API versions.

## Version 2 (>= WordPress 5.6)

- Moves the responsibility to render the block element wrapper in the editor to the block author using the `useBlockProps()` hook.
- Generates classnames and styles are not added automatically to the saved markup for static blocks, block authors are required to explicitely use `useBlockProps.save()` in their `save` functions to retrieve the generated classes and styles to apply on the block wrapper.
- To render the block element wrapper for the block's `edit` implementation, the block author must use the `useBlockProps()` hook.
- The generated class names and styles are no longer added automatically to the saved markup for static blocks when `save` is processed. To include them, the block author must explicitly use `useBlockProps.save()` and add to their block wrapper.

## Version 1

Expand Down

0 comments on commit f7ab9dc

Please sign in to comment.