Creates a text component for displaying static or dynamic text content.
Configuration object
A JSX element representing the text component
Basic usage with static text
text({ text: 'Hello, World!'}); Copy
text({ text: 'Hello, World!'});
Usage with dynamic text from central state
text({ text: (state) => `Welcome back, ${state.userName}!`}); Copy
text({ text: (state) => `Welcome back, ${state.userName}!`});
Usage with info callout text
text({ text: ':::info\nThis is an informational message\n:::'}); Copy
text({ text: ':::info\nThis is an informational message\n:::'});
Usage with warning callout text
text({ text: ':::warn\nThis is a warning message\n:::'}); Copy
text({ text: ':::warn\nThis is a warning message\n:::'});
Creates a text component for displaying static or dynamic text content.