Type Alias: StoryContentItems
StoryContentItems =
Conditional<Component>[]
Defined in: packages/core/src/passages/story/types.ts:988
Array returned by a StoryContentFn.
Accepts false, null and undefined entries, which are removed before
the story is rendered. That makes conditional content expressible inline
instead of through a callback that returns undefined.
Example
const items: StoryContentItems = [
{ type: 'text', content: 'A locked door blocks your way.' },
player.hasKey && { type: 'text', content: 'Your key fits the lock.' }
];