Overview of JSX components for Slack Block Kit
mainThe jsx-slack library provides a comprehensive set of JSX components that map directly to Slack's Block Kit UI framework. These components allow you to build complex Slack interfaces (messages, modals, and home tabs) using a declarative JSX syntax instead of manually constructing large JSON objects.
Components are organized into three main categories:
- Block containers: The top-level wrappers for different Slack views, such as
<Blocks>for messages,<Modal>for modal dialogs, and<Home>for home tabs. - Layout blocks: Structural components that define the layout of a view, including
<Section>,<Divider>,<Image>,<Header>,<Actions>,<Context>,<Input>,<Video>,<File>, and<Call>. - Block elements: Interactive and content-based components that live inside layout blocks. This includes:
- Interactive components:
<Button>,<Select>,<UsersSelect>,<DatePicker>,<CheckboxGroup>, etc. - Composition objects:
<Mrkdwn>for formatted text and<Confirm>for confirmation dialogs. - Input components:
<Input>(text/hidden/submit) and<Textarea>for user data entry.
- Interactive components: