Open cbou opened 4 years ago
Since 251cf88 you can get all attributes for a block via the attributesJSON
field (added because blocksJSON
already existed, and I thought it made sense to have a similar thing for attributes). You would need to parse this JSON client-side, but I think it side-steps the problem that value
in the proposed solution would either need to be able to hold all possible attribute types (schema nightmare?) or becoming serialized to a common type, such as a string.
@cbou Is attributesJSON
sufficient for your use case?
According to the doc, you always needs to need the type of a block in order to get the attributes of this block. This could lead to a ton of codes in order to get all attributes.
The project Quartz/wp-graphql-content-blocks has another approach:
Is it something that could be implemented in this plugin?