Closed danialvz closed 1 year ago
I haven't looked into block contexts yet (nor do I fully understand them) but it looks like I'm missing 2 new variables added to the block render callback.
$wp_block
and $context
are currently not getting passed.
I'll read into it more unless you have any input on how to proceed.
I added the missing call for $context
in the block render callback but I'm only seeing it return output like:
What were you trying to achieve exactly? Maybe you can pass a specific context using $supports
or something? Can you give me an example of a use-case for this so I can better understand?
I'm thinking just needing $context
available is not all that you needed.
Hey log1x, not sure if related, but I was looking for something that sounds a bit similar to OP
I need to supply uses_context
value when registering a new block, so that when the block placed within a query loop, it can retrieve the queryId value created by the query loop block. It is ultimately for a query filter block that will be exposed to the user.
I've created a pull request for the update #153
Hi! This might be a dumb question, but I wasn't able to find any info on this. Is there a way to define block context using the Block class definition?
Thanks