React Native Screen Component Creation

VerifiedSafe

Creates React Native screen components in src/screens/ directory with standardized template. Used for requests like "add a screen" or "create home screen".

Sby Skills Guide Bot
DevelopmentBeginner
506/2/2026
Claude Code
#react-native#screens#component-creation#mobile-development

Recommended for

Our review

Creates a React Native screen component with a consistent template.

Strengths

  • Automatically handles naming conventions.
  • Ensures full-screen layout with flex: 1.
  • Includes common imports and styles.

Limitations

  • Assumes Expo and React Navigation are used.
  • Does not generate custom logic or styling.
  • Limited to basic boilerplate without advanced configuration.
When to use it

When adding a new screen to a React Native project.

When not to use it

When the screen logic is very specific or requires complex state management that should be generated differently.

Security analysis

Safe
Quality score85/100

The skill only creates a directory and writes a static React Native screen template to a file under src/screens/. No network, destructive commands, or handling of secrets. The Bash usage is limited to safe 'mkdir -p' and file creation via Write tool, with no user input injected into the executed commands.

No concerns found

Examples

Créer un écran d'accueil
Ajoute un écran d'accueil avec un titre et un bouton de connexion.
Create a Profile Screen
Create a Profile screen with the user's name and avatar placeholder.
Ajouter un écran de paramètres
Ajoute un écran de paramètres avec des options de base.

name: screen description: React Nativeの画面(Screen)コンポーネントを作成する。「画面を追加して」「ホーム画面を作って」などのリクエストで使用する。 allowed-tools: Read, Write, Edit, Glob, Grep, Bash argument-hint: [画面名]

画面コンポーネント作成

src/screens/ に画面用コンポーネントを作成する。

手順

  1. src/screens/ ディレクトリが存在しなければ作成する
  2. PascalCase のファイル名で .tsx ファイルを作成する(例: $ARGUMENTS.tsx または ${ARGUMENTS}Screen.tsx
  3. 画面名が "Screen" で終わっていなければ自動でサフィックスを付ける

テンプレート

import React from 'react';
import { StyleSheet, View, Text } from 'react-native';
import { StatusBar } from 'expo-status-bar';

export const ScreenNameScreen: React.FC = () => {
  return (
    <View style={styles.container}>
      <Text style={styles.title}>ScreenName</Text>
      <StatusBar style="auto" />
    </View>
  );
};

const styles = StyleSheet.create({
  container: {
    flex: 1,
    backgroundColor: '#fff',
    alignItems: 'center',
    justifyContent: 'center',
  },
  title: {
    fontSize: 24,
    fontWeight: 'bold',
  },
});

ルール

  • 画面コンポーネントは flex: 1 でフルスクリーンにする
  • SafeAreaViewStatusBar を適切に使う
  • ナビゲーションライブラリが導入済みなら、navigation props の型を適切に定義する
  • ビジネスロジックが複雑な場合はカスタムフックに切り出す
Related skills