Props
الخصائص (Props)
GLS-000078
Definition
Data passed from a parent component to a child component in React.
البيانات التي تُمرَّر من مكوّن أب إلى مكوّن ابن في React.
Why It Matters
Props is how you make reusable components — the same ProjectCard component can display any project by receiving different props each time.
Props هو الطريقة التي تجعل بها المكونات قابلة لإعادة الاستخدام — نفس مكوّن ProjectCard يمكنه عرض أي مشروع عن طريق تلقي props مختلفة في كل مرة.
Full Definition
Example Usage
“<ProjectCard title='Food App' difficulty='beginner' /> passes the title and difficulty as props to the ProjectCard component.”
“<ProjectCard title='تطبيق طعام' difficulty='beginner' /> يمرّر العنوان والصعوبة كـ props إلى مكوّن ProjectCard.”
AI Builder Tips
Avoid these mistakes when using Props:
Trying to modify props inside a child component
Passing too many props (prop drilling) — use Context instead
Not defining prop types with TypeScript interfaces
Sign in to unlock guided AI explanations from AI Teacher.
Generate a Prompt
Copy this prompt and use it directly with any AI model — no setup needed.
Help me build a project using Props. Explain: 1. What is Props and why it matters 2. The core architecture and required tools 3. Step-by-step implementation plan 4. Common mistakes to avoid: Trying to modify props inside a child component, Passing too many props (prop drilling) — use Context instead, Not defining prop types with TypeScript interfaces 5. Best practices and production tips