heroui-native
Fungsinya
Skill ini memandu pembuatan antarmuka aplikasi mobile dengan pustaka komponen HeroUI Native untuk React Native. Skill mencakup instalasi pustaka, pengaturan tema terang dan gelap, serta penggunaan komponennya.
Kapan dipakai
- βSaat Anda membangun layar aplikasi mobile dengan HeroUI Native.
- βKetika Anda ingin mengatur tema terang dan gelap untuk aplikasi React Native.
- βSaat Anda membutuhkan dokumentasi untuk komponen HeroUI Native.
Link skill
https://github.com/heroui-inc/heroui/blob/v3/skills/heroui-native/SKILL.mdSalin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.
Cara pakai
Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.
Pesan siap tempel
Untuk Claude Code, Codex, atau Cursor: jalankan di folder proyek, lalu skill langsung terpasang.
Unduh SKILL.md lalu taruh di folder skill agen Anda.
Contoh permintaan ke AI
βBangun layar masuk untuk aplikasi React Native saya dengan tombol dan kolom teks HeroUI Native.β
5 skill baru setiap minggu. 1 menit baca.
Cara kerjanya
Agent membaca dokumentasi komponen native sebelum menulis kode, karena pola web tidak berlaku untuk mobile. Agent memasang pustaka, mengatur tema, lalu membangun layar dengan komponen yang tepat.
Konten teknis (SKILL.md asli)
Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.
HeroUI Native Development Guide
HeroUI Native is a component library built on Uniwind (Tailwind CSS for React Native) and React Native, providing accessible, customizable UI components for mobile applications.
Installation
curl -fsSL https://heroui.com/install | bash -s heroui-native
CRITICAL: Native Only - Do Not Use Web Patterns
This guide is for HeroUI Native ONLY. Do NOT apply HeroUI React (web) patterns β the package, styling engine, and color format all differ:
| Feature | React (Web) | Native (Mobile) |
|---|---|---|
| Styling | Tailwind CSS v4 | Uniwind (Tailwind for React Native) |
| Colors | oklch format | HSL format |
| Package | @heroui/react |
heroui-native |
| Platform | Web browsers | iOS & Android |
// CORRECT β Native pattern
import { Button } from "heroui-native";
<Button variant="primary" onPress={() => console.log("Pressed!")}>
Click me
</Button>;
Always fetch Native docs before implementing.
Core Principles
- Semantic variants (
primary,secondary,tertiary) over visual descriptions - Composition over configuration (compound components)
- Theme variables with HSL color format
- React Native StyleSheet patterns with Uniwind utilities
Accessing Documentation & Component Information
For component details, examples, props, and implementation patterns, always fetch documentation:
Using Scripts
# List all available components
node scripts/list_components.mjs
# Get component documentation (MDX)
node scripts/get_component_docs.mjs Button
node scripts/get_component_docs.mjs Button Card TextField
# Get theme variables
node scripts/get_theme.mjs
# Get non-component docs (guides, releases)
node scripts/get_docs.mjs /docs/native/getting-started/theming
Direct MDX URLs
Component docs: fetch .mdx with a concrete kebab-case slug. Run node scripts/list_components.mjs when the slug is unknown, and never fetch a URL that still contains a placeholder.
Examples:
- Button:
https://heroui.com/docs/native/components/button.mdx - Dialog:
https://heroui.com/docs/native/components/dialog.mdx - TextField:
https://heroui.com/docs/native/components/text-field.mdx
Getting started guides: use a concrete topic URL such as https://heroui.com/docs/native/getting-started/quick-start.mdx.
Important: Always fetch component docs before implementing. The MDX docs include complete examples, props, anatomy, and API references.
Installation Essentials
Quick Install
npm i heroui-native react-native-reanimated react-native-gesture-handler react-native-safe-area-context @gorhom/bottom-sheet react-native-svg react-native-worklets tailwind-merge tailwind-variants
Framework Setup (Expo - Recommended)
- Install dependencies:
npx create-expo-app MyApp
cd MyApp
npm i heroui-native uniwind tailwindcss
npm i react-native-reanimated react-native-gesture-handler react-native-safe-area-context @gorhom/bottom-sheet react-native-svg react-native-worklets tailwind-merge tailwind-variants
- Create
global.css:
@import "tailwindcss";
@import "uniwind";
@import "heroui-native/styles";
@source "./node_modules/heroui-native/lib";
- Wrap app with providers:
import { GestureHandlerRootView } from "react-native-gesture-handler";
import { HeroUINativeProvider } from "heroui-native";
import "./global.css";
export default function Layout() {
return (
<GestureHandlerRootView style={{ flex: 1 }}>
<HeroUINativeProvider>
<App />
</HeroUINativeProvider>
</GestureHandlerRootView>
);
}
Critical Setup Requirements
- Uniwind is Required - HeroUI Native uses Uniwind (Tailwind CSS for React Native)
- HeroUINativeProvider Required - Wrap your app with
HeroUINativeProvider - GestureHandlerRootView Required - Wrap with
GestureHandlerRootViewfrom react-native-gesture-handler - Use Compound Components - Components use compound structure (e.g.,
Card.Header,Card.Body) - Use onPress, not onClick - React Native uses
onPressevent handlers - Platform-Specific Code - Use
Platform.OSfor iOS/Android differences
Component Patterns
HeroUI Native uses **compound component pattern
Pertanyaan umum
Bisakah saya memakai ulang kode HeroUI web saya?
Tidak. Pustaka native memakai format gaya dan warna yang berbeda, sehingga pola web tidak berlaku.
Apakah mode gelap didukung?
Ya. Skill mencakup konfigurasi tema gelap dan terang.
Platform mana yang menjadi target?
Aplikasi iOS dan Android yang dibangun dengan React Native.
Detail
Deskripsi asli dari pembuat
HeroUI Native component library for React Native (Tailwind v4 via Uniwind). Use when building mobile UIs with HeroUI Native β creating Buttons, Cards, TextFields, Dialogs; installing heroui-native; configuring dark/light themes; or fetching component docs. Keywords: HeroUI Native, heroui-native, React Native UI, Uniwind, mobile components.
repo: heroui-inc/heroui
Popularitas
- Bintang GitHub
- 31k
- Peringkat
- #9326
- Lisensi
- Apache-2.0
- Diperbarui
- 2/11/2026
Komentar
- β¦
Skill lain dari repositori ini
heroui-migration
31kMembantu agent Anda meningkatkan aplikasi web HeroUI v2 ke HeroUI v3, termasuk pola komponen yang berubah dan hook yang dihapus.
heroui-react
31kMembantu agent Anda membangun antarmuka web React dengan komponen HeroUI v3, seperti tombol, modal, formulir, dan kartu.
Skill serupa
android-clean-architecture
280kMembuat agent Anda mengatur proyek Android dengan efisien. Struktur kodenya dibuat agar lebih mudah dirawat dan pengembangan fitur baru.
compose-multiplatform-patterns
280kMembantu agent Anda menggunakan pola Compose Multiplatform dan Jetpack Compose di proyek KMP, mencakup state, navigasi, theming, dan performa.
dart-flutter-patterns
280kMembuat agent Anda menulis kode untuk aplikasi Dart dan Flutter. Menggunakan pola modern agar aplikasi kokoh dan mudah dikelola.