Overview
Uniwind Pro allows you to update any React Native style prop without triggering component re-renders. It leverages direct Shadow Tree updates to inject styles without waking up React. By creating a direct, optimized highway between your classNames and the native layer, we eliminate rendering lag entirely.Uniwind Pro is built on the 2nd generation Unistyles C++ engine, a new and improved version that powers the shadow tree update mechanism.
The Traditional Re-render Problem
In standard React Native, these scenarios trigger component re-renders:| Trigger | What happens |
|---|---|
useColorScheme() | Component subscribes to system appearance changes and re-renders when it changes |
| Theme Context Provider | All consumers re-render when context value updates |
Appearance.addChangeListener() | Manual subscription requires state update, which triggers re-render |
How Uniwind Pro Updates Views
Uniwind Pro bypasses React’s reconciliation entirely for style changes:Supported Components
The following components support shadow tree updates with no re-renders. All components supportclassName for the main style, and additional props use the {propName}ClassName pattern.
View
View
| Prop | Description |
|---|---|
className | Main styles |
Text
Text
| Prop | Description |
|---|---|
className | Main styles |
selectionColorClassName | Text selection highlight color |
TextInput
TextInput
| Prop | Description |
|---|---|
className | Main styles |
cursorColorClassName | Cursor/caret color |
selectionColorClassName | Text selection highlight color |
selectionHandleColorClassName | Selection handle color (Android) |
underlineColorAndroidClassName | Underline color (Android) |
placeholderTextColorClassName | Placeholder text color |
Image
Image
| Prop | Description |
|---|---|
className | Main styles |
tintColorClassName | Image tint color |
ImageBackground
ImageBackground
| Prop | Description |
|---|---|
className | Main styles |
tintColorClassName | Image tint color |
Switch
Switch
| Prop | Description |
|---|---|
className | Main styles |
thumbColorClassName | Thumb/knob color |
trackColorOnClassName | Track color when on |
trackColorOffClassName | Track color when off |
ios_backgroundColorClassName | Background color (iOS) |
ActivityIndicator
ActivityIndicator
| Prop | Description |
|---|---|
className | Main styles |
colorClassName | Spinner color |
Button
Button
Modal
Modal
| Prop | Description |
|---|---|
className | Main styles |
backdropColorClassName | Backdrop/overlay color |
RefreshControl
RefreshControl
| Prop | Description |
|---|---|
className | Main styles |
tintColorClassName | Spinner tint color (iOS) |
titleColorClassName | Title text color (iOS) |
progressBackgroundColorClassName | Progress background (Android) |
colorsClassName | Spinner colors array (Android) |
ScrollView
ScrollView
| Prop | Description |
|---|---|
className | Main styles |
contentContainerClassName | Content container styles |
endFillColorClassName | End fill color (Android) |
FlatList
FlatList
| Prop | Description |
|---|---|
className | Main styles |
contentContainerClassName | Content container styles |
columnWrapperClassName | Column wrapper styles (numColumns > 1) |
ListHeaderComponentClassName | Header component styles |
ListFooterComponentClassName | Footer component styles |
endFillColorClassName | End fill color (Android) |
SectionList
SectionList
| Prop | Description |
|---|---|
className | Main styles |
contentContainerClassName | Content container styles |
ListHeaderComponentClassName | Header component styles |
ListFooterComponentClassName | Footer component styles |
endFillColorClassName | End fill color (Android) |
VirtualizedList
VirtualizedList
| Prop | Description |
|---|---|
className | Main styles |
contentContainerClassName | Content container styles |
ListHeaderComponentClassName | Header component styles |
ListFooterComponentClassName | Footer component styles |
endFillColorClassName | End fill color (Android) |
KeyboardAvoidingView
KeyboardAvoidingView
| Prop | Description |
|---|---|
className | Main styles |
contentContainerClassName | Content container styles |
Pressable
Pressable
| Prop | Description |
|---|---|
className | Main styles (supports pressed:, disabled: variants) |
TouchableOpacity
TouchableOpacity
| Prop | Description |
|---|---|
className | Main styles |
TouchableWithoutFeedback
TouchableWithoutFeedback
| Prop | Description |
|---|---|
className | Main styles |
TouchableNativeFeedback
TouchableNativeFeedback
| Prop | Description |
|---|---|
className | Main styles (supports pressed:, disabled: variants) |
SafeAreaView
SafeAreaView
| Prop | Description |
|---|---|
className | Main styles |
Components Requiring Re-renders
Some React Native components cannot use shadow tree updates due to their internal implementation:| Component | Reason |
|---|---|
InputAccessoryView | No shadow node exposed by React Native |
TouchableHighlight | Uses internal React state to manage underlayColor |
useResolveClassNames hook which subscribes to UniwindListener and triggers React re-renders when dependencies change.
Summary
| Approach | Re-renders | Update Speed | Flickering |
|---|---|---|---|
| Traditional React | Every themed component | Sequential | Yes |
| Uniwind Pro | None (for most components) | Single frame | No |
Uniwind Pro achieves single-frame theme updates by bypassing React’s reconciliation entirely for style changes, resulting in smoother transitions and better performance.
Related
Theme Transitions
Add smooth animated transitions when switching themes
Unistyles
Learn more about the C++ engine powering Uniwind Pro