About react-native-elements
react-native-elements is a best-practices skill for applications built with React Native Elements. Its 45 prioritized rules cover setup, theming, component use, performance, styling, and events.
Key features
- 0145 rules across eight categories
- 02ThemeProvider and createTheme guidance
- 03Component selection and configuration
- 04FlatList performance recommendations
- 05Styling and event handling patterns
Use cases
- 01Setting up themes in a new application
- 02Building lists and forms with RNE components
- 03Reviewing FlatList performance and rendering
- 04Applying theme-aware styles and callbacks
Install
Copy the command and run it in a terminal.
$
npx skills add https:/ / github.com/ pproenca/ dot-skills --skill react-native-elementsAfter installing, type/react-native-elementsin Claude Code to confirm it loaded.
Bundled files
References and scripts installed along with SKILL.md.
metadata.jsonassets/templates/_template.mdreferences/_sections.mdadv-custom-component.mdadv-image-component.mdadv-makeStyles.mdadv-overlay-modal.mdadv-platform-specific.mdcomp-avatar-vs-image.mdcomp-button-type.mdcomp-icon-source.mdcomp-input-over-textinput.mdcomp-listitem-over-view.mdcomp-searchbar-platform.mdevent-avoid-anonymous.mdevent-debounce-search.mdevent-input-handlers.mdevent-listitem-onpress.mdevent-usecallback.mdlist-getitemlayout.mdlist-keyextractor.mdlist-memo-items.mdlist-removeClipped.mdlist-renderitem-callback.mdlist-virtualized.mdlist-windowsize.mdprops-button-color.mdprops-disabled-styling.mdprops-icon-configuration.mdprops-input-validation.mdDetails
From the project READMECommunity React Native Elements Best Practices
Comprehensive best practices guide for React Native Elements applications. Contains 45 rules across 8 categories, prioritized by impact to guide component usage, theming, and performance optimization.
When to Apply
Reference these guidelines when:
- Setting up React Native Elements in a new project
- Configuring ThemeProvider and createTheme
- Building lists with ListItem components
- Implementing form inputs with Input and SearchBar
- Optimizing FlatList performance with RNE components
- Reviewing code using React Native Elements
Rule Categories by Priority
| Priority | Category | Impact | Prefix |
|---|---|---|---|
| 1 | Import & Setup | CRITICAL | setup- |
| 2 | Theme Architecture | CRITICAL | theme- |
| 3 | Component Selection | HIGH | comp- |
| 4 | List Performance | HIGH | list- |
| 5 | Props & Configuration | MEDIUM-HIGH | props- |
| 6 | Styling Patterns | MEDIUM | style- |
| 7 | Callbacks & Events | MEDIUM | event- |
| 8 | Advanced Patterns | LOW | adv- |
Quick Reference
1. Import & Setup (CRITICAL)
setup-themeprovider- Wrap app with ThemeProvider for consistent themingsetup-imports- Use @rneui/themed vs @rneui/base correctlysetup-createtheme- Type-safe theme configuration with createThemesetup-tree-shaking- Enable proper tree-shaking for bundle sizesetup-safe-area- Configure SafeAreaProvider for notched devices
2. Theme Architecture (CRITICAL)
theme-usetheme-hook- Access theme reactively with useThemetheme-dark-mode- Configure light/dark mode with createThemetheme-component-defaults- Set component defaults in themetheme-updatetheme- Runtime theme updates without remounttheme-color-scheme- Sync with system color schemetheme-custom-colors- Extend theme with custom colors safely
3. Component Selection (HIGH)
comp-listitem-over-view- Use ListItem for list rowscomp-input-over-textinput- Use Input for form fieldscomp-searchbar-platform- Platform-specific SearchBar variantscomp-button-type- Use Button type prop for variantscomp-icon-source- Choose Icon type wisely for bundle sizecomp-avatar-vs-image- Use Avatar for profile images
4. List Performance (HIGH)
list-memo-items- Memoize ListItem in FlatListlist-keyextractor- Always provide keyExtractorlist-getitemlayout- Use getItemLayout for fixed heightslist-renderitem-callback- Extract renderItem with useCallbacklist-windowsize- Configure windowSize for memory balancelist-virtualized- Use FlatList over ScrollViewlist-removeClipped- Configure removeClippedSubviews carefully
5. Props & Configuration (MEDIUM-HIGH)
props-loading-state- Use loading prop for async operationsprops-disabled-styling- Configure disabledStyle for feedbackprops-input-validation- Use errorMessage for validationprops-icon-configuration- Configure Icon props correctlyprops-searchbar-loading- Show loading state in SearchBarprops-button-color- Use color prop for semantic colors
6. Styling Patterns (MEDIUM)
style-stylesheet- Use StyleSheet.create over inline objectsstyle-containerStyle- Use containerStyle for wrappersstyle-usememo-dynamic- Memoize dynamic stylesstyle-theme-colors- Use theme colors over hardcoded valuesstyle-component-props- Prefer component-specific style props
7. Callbacks & Events (MEDIUM)
event-usecallback- Wrap handlers in useCallbackevent-debounce-search- Debounce SearchBar onChangeTextevent-listitem-onpress- Pass item data correctlyevent-avoid-anonymous- Avoid anonymous functions in rendersevent-input-handlers- Configure Input handlers efficiently
8. Advanced Patterns (LOW)
adv-custom-component- Wrap RNE components correctlyadv-platform-specific- Handle platform-specific propsadv-makeStyles- Use makeStyles for theme-aware stylesadv-overlay-modal- Choose Overlay vs Modal correctlyadv-image-component- Configure Avatar ImageComponent for caching
How to Use
Read individual reference files for detailed explanations and code examples:
- Section definitions - Category structure and impact levels
- Rule template - Template for adding new rules
Reference Files
| File | Description |
|---|---|
| references/_sections.md | Category definitions and ordering |
| assets/templates/_template.md | Template for new rules |
| metadata.json | Version and reference information |
Comments
Markdown supported