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
The example section in block registration document, it use object expression, like innerBlocks: { ... } to adding innerBlocks for previewing.
I got Cannot read property 'attributes' of undefined error, by following the way above.
Describe the bug
The example section in block registration document, it use object expression, like
innerBlocks: { ... }
to adding innerBlocks for previewing.I got
Cannot read property 'attributes' of undefined
error, by following the way above.But, I found the the
core/cover
block use array expression, likeinnerBlocks: [ ... ]
. It works well.https://github.com/WordPress/gutenberg/blob/master/packages/block-library/src/cover/index.js#L32
We should fix the example code in the document , from
innerBlocks: { ... }
. toinnerBlocks: [ ... ]
.To reproduce
Adding innerBlocks for block example in block registration by
innerBlocks: { ... }
.Expected behavior
Can see Block Preview.
Screenshots
none
Editor version (please complete the following information):
Desktop (please complete the following information):
Smartphone (please complete the following information):
none
Additional context
none
The text was updated successfully, but these errors were encountered: