strapi / blocks-react-renderer

A React renderer for the Strapi's Blocks rich text editor
Other
107 stars 15 forks source link

[feat]: Exporting types to have more modularity in our implementation #38

Open oktapodia opened 1 month ago

oktapodia commented 1 month ago

A clear and concise description of what the feature is

the package got a lot of interfaces not exported which is making the usage harder for an example, BlocksRendererProps if we want to auto-generate the blocks

Why should this feature be included?

That's quite common to export the type for reusability

Please provide an example for how this would work

interface BlocksRendererProps {
    content: RootNode[];
    blocks?: Partial<BlocksComponents>;
    modifiers?: Partial<ModifiersComponents>;
}

to

export interface BlocksRendererProps {
    content: RootNode[];
    blocks?: Partial<BlocksComponents>;
    modifiers?: Partial<ModifiersComponents>;
}