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
{{ message }}
This repository was archived by the owner on Jan 19, 2026. It is now read-only.
Current behavior:
We are using @storyblok/jsrenderRichtext function to render the richtext fetched from Storyblok. After migrating to v4 of the storyblok-cli we noticed that there is a discrepancy in the types generated by the cli and the typ expected by renderRichtext. This becomes a static issue when exactOptionalPropertyTypes: true set in tsconfig.json.
Signature of renderRichtext:
export declare function renderRichText<T = string>(data: StoryblokRichTextNode<T>, options?: StoryblokRichTextOptions<T>): T | undefined;
Current behavior:
We are using
@storyblok/jsrenderRichtextfunction to render the richtext fetched from Storyblok. After migrating to v4 of the storyblok-cli we noticed that there is a discrepancy in the types generated by the cli and the typ expected byrenderRichtext. This becomes a static issue whenexactOptionalPropertyTypes: trueset intsconfig.json.Signature of
renderRichtext:where
The generated
StoryblokRichtexttype:Expected behavior:
The type match and
renderRichtextcan be used as expected.Steps to reproduce:
@storyblok/jsrenderRichtextfunction with a some attribute of typeStoryblokRichtextgenerated via the CLI tool.tsconfig.jsonmust specifyexactOptionalPropertyTypes: trueOther information:
Looking forward to getting this resolved.