Exposing group and block types when generating types

default discord avatar
7 months ago

I want to write some generic mappings that maps from payload's types to props for my frontend React components. Blocks and groups aren't exposed at the top level, so I'm having to manually pick them out by unpacking arrays and extracting specific blocks.

Is it possible to expose these when generating types? Or is there a simpler way for me to define these types based on the generated typings?

Open the post
Continue the discussion in Discord
Like what we're doing?
Star us on GitHub!


Connect with the Payload Community on Discord



Can't find what you're looking for?

Get help straight from the Payload team with an Enterprise License.