Default component fallback (important)
Customization is opt-in per slot. You never need to register every component.
How it works internally
code
configureChat({ ui: { components: { MessageBubble: MyBubble } } }) ↓runtime.config merges your partial over DEFAULT_CHAT_UI (components: {}) ↓At render: getUiConfig().components.MessageBubble || MessageBubble ↓Custom passed? → MyBubbleNot passed? → package MessageBubble (built-in default)Rules:
Code pattern inside the package
Every wired slot follows this pattern (src/screen/chat/ChatRoomScreen.tsx):
tsx
const ComposerComponent = ui.components.MessageComposer || MessageComposer;const HeaderComponent = ui.components.ChatRoomHeader || ChatRoomHeader;Your component receives the same props as the package default. Import the prop type (MessageBubbleProps, MessageComposerProps, ChatRoomHeaderProps, ConversationListItemProps) from the package.
Wrapping instead of rebuilding
The defaults are exported — wrap them when you only need extra layout or styling:
tsxsrc/chat/custom/MyBubble.tsx
// src/chat/custom/MyBubble.tsximport React from 'react';import {View} from 'react-native';import {MessageBubble, type MessageBubbleProps} from '@realtimexsco/live-chat-react-native'; export const MyBubble = (props: MessageBubbleProps) => ( <View style={{paddingHorizontal: 4}}> <MessageBubble {...props} /> </View>);