React Native Basics
View, Text, Image, ScrollView, FlatList, StyleSheet, Flexbox layout
1What is the basic component used to create containers in React Native?
What is the basic component used to create containers in React Native?
Câu trả lời
The View component is the fundamental container in React Native, equivalent to a div in HTML. It allows grouping other components, applying styles, and managing layout via Flexbox. Unlike web, React Native uses View instead of div because it must be translated to native components (UIView on iOS, android.view on Android).
2What is the main difference between Text and View in React Native?
What is the main difference between Text and View in React Native?
Câu trả lời
The Text component is the only component capable of displaying text in React Native. Unlike the web where any element can contain text, React Native requires all text to be wrapped in a Text component. View cannot contain raw text directly - attempting to do so generates an error.
3How to display a local image in React Native?
How to display a local image in React Native?
Câu trả lời
To display a local image in React Native, use the Image component with the source prop and the require() function. This approach allows the Metro bundler to resolve the image path at build time and optimize assets. Remote images use an object with a uri property instead.
Which property is required to display a remote image (URL) with the Image component?
What is the main difference between ScrollView and FlatList?
+19 câu hỏi phỏng vấn
Các chủ đề phỏng vấn React Native khác
JavaScript Essentials
React Fundamentals
React Hooks
TypeScript for React & React Native
React Native Components & API
React Native Styling & Layout
React Native Navigation
React Native State Management
React Native Networking & API
Data Persistence
Forms & Validation
React Native Animations
Native Modules & Bridge
Platform-Specific Code
Permissions & Device APIs
Push Notifications
React Native Testing
React Native Debugging
Build & Deployment
Expo vs React Native Bare
Performance Optimization
Memory Management
Architecture Patterns
React Native New Architecture
Security Best Practices
Offline-First Architecture
React Native CI/CD
Monorepo & Code Sharing
Advanced Topics
App Lifecycle & Background Execution
Authentication & Session Management
Monitoring & Crash Reporting
Nắm vững React Native cho lần phỏng vấn tiếp theo
Truy cập tất cả câu hỏi, flashcards, bài kiểm tra kỹ thuật, bài tập code review và mô phỏng phỏng vấn.
Bắt đầu miễn phí