ContentNode

ContentNode component for specifying data used to configure nodes and components

import { ContentNode } from "@roku-sdk/components";
ContentNode(props: IContentNodeProps): JSX.Element

Description

ContentNode component for specifying data used to configure nodes and components.

Many SceneGraph nodes (lists, grids, panels) require a ContentNode as the specification of their content field. ContentNodes are structured as a parent node with child ContentNode descendants that carry the actual content data.

Parameters

NameTypeDescription
propsIContentNodeProps

Example

// Simple content node for a LabelList
<labelList>
    <contentNode role="content">
        <contentNode title="Movies" description="Browse movies" />
        <contentNode title="TV Shows" description="Browse TV series" />
        <contentNode title="Settings" description="App settings" />
    </contentNode>
</labelList>
// Content node with playback metadata for Video
<contentNode
    title="My Video"
    url="https://example.com/video.mp4"
    streamFormat="mp4"
/>

What’s Next

Did this page help you?