Master React Native fundamentals - components, styling, layout, and Expo
Provides React Native fundamentals for building mobile apps with core components, StyleSheet, Flexbox layouts, and Expo setup. Use when creating or debugging React Native components, styling, or platform-specific code.
/plugin marketplace add pluginagentmarketplace/custom-plugin-react-native/plugin install react-native-assistant@pluginagentmarketplace-react-nativeThis skill inherits all available tools. When active, it can use any tool Claude has access to.
assets/config.yamlassets/schema.jsonreferences/GUIDE.mdreferences/PATTERNS.mdscripts/validate.pyLearn production-ready React Native fundamentals including core components, StyleSheet, Flexbox, and Expo SDK.
After completing this skill, you will be able to:
View - Container component (like div)
Text - Text display (required for strings)
Image - Image rendering
ScrollView - Scrollable container
FlatList - Optimized list rendering
TextInput - User input
Pressable - Touch handling
// StyleSheet.create for performance
const styles = StyleSheet.create({
container: {
flex: 1,
backgroundColor: '#fff',
padding: 16,
},
title: {
fontSize: 24,
fontWeight: 'bold',
color: '#1a1a1a',
},
});
// Common patterns
flexDirection: 'row' | 'column' // Main axis
justifyContent: 'center' | 'space-between' // Main axis alignment
alignItems: 'center' | 'stretch' // Cross axis alignment
flex: 1 // Grow to fill
import { Platform } from 'react-native';
// Method 1: Platform.select
const styles = StyleSheet.create({
shadow: Platform.select({
ios: { shadowColor: '#000', shadowOpacity: 0.1 },
android: { elevation: 4 },
}),
});
// Method 2: Platform.OS
if (Platform.OS === 'ios') {
// iOS specific code
}
# Create new project
npx create-expo-app MyApp
cd MyApp
# Start development
npx expo start
# Build for production
eas build --platform all
import React from 'react';
import { View, Text, StyleSheet, FlatList, Pressable } from 'react-native';
interface Item {
id: string;
title: string;
}
export default function App() {
const [items, setItems] = React.useState<Item[]>([
{ id: '1', title: 'Learn React Native' },
{ id: '2', title: 'Build first app' },
]);
return (
<View style={styles.container}>
<Text style={styles.title}>My Tasks</Text>
<FlatList
data={items}
keyExtractor={(item) => item.id}
renderItem={({ item }) => (
<Pressable style={styles.item}>
<Text>{item.title}</Text>
</Pressable>
)}
/>
</View>
);
}
const styles = StyleSheet.create({
container: { flex: 1, padding: 16, backgroundColor: '#f5f5f5' },
title: { fontSize: 24, fontWeight: 'bold', marginBottom: 16 },
item: { backgroundColor: '#fff', padding: 16, marginBottom: 8, borderRadius: 8 },
});
| Error | Cause | Solution |
|---|---|---|
| "Text strings must be wrapped" | Raw text outside <Text> | Wrap all text in <Text> |
| Styles not applying | Plain object vs StyleSheet | Use StyleSheet.create() |
| FlatList not scrolling | No height/flex | Add flex: 1 to parent |
| Image not showing | Invalid source | Check URI or require path |
Skill("react-native-basics")
Bonded Agent: 01-react-native-fundamentals
This skill should be used when the user asks to "create an agent", "add an agent", "write a subagent", "agent frontmatter", "when to use description", "agent examples", "agent tools", "agent colors", "autonomous agent", or needs guidance on agent structure, system prompts, triggering conditions, or agent development best practices for Claude Code plugins.
This skill should be used when the user asks to "create a slash command", "add a command", "write a custom command", "define command arguments", "use command frontmatter", "organize commands", "create command with file references", "interactive command", "use AskUserQuestion in command", or needs guidance on slash command structure, YAML frontmatter fields, dynamic arguments, bash execution in commands, user interaction patterns, or command development best practices for Claude Code.
This skill should be used when the user asks to "create a hook", "add a PreToolUse/PostToolUse/Stop hook", "validate tool use", "implement prompt-based hooks", "use ${CLAUDE_PLUGIN_ROOT}", "set up event-driven automation", "block dangerous commands", or mentions hook events (PreToolUse, PostToolUse, Stop, SubagentStop, SessionStart, SessionEnd, UserPromptSubmit, PreCompact, Notification). Provides comprehensive guidance for creating and implementing Claude Code plugin hooks with focus on advanced prompt-based hooks API.