React Native Styling & Layout
Flexbox, absolute positioning, responsive design, safe area, platform-specific styles
1What is the default flexDirection in React Native?
What is the default flexDirection in React Native?
Antwoord
In React Native, flexDirection defaults to 'column', unlike on the web where it defaults to 'row'. This means child elements are arranged vertically from top to bottom by default. This difference reflects typical mobile interface conventions, where vertical layouts are more common.
2How to create a reusable style in React Native?
How to create a reusable style in React Native?
Antwoord
StyleSheet.create() is the recommended method for creating styles in React Native. It allows defining a style object that can be reused across multiple components. This approach optimizes performance by validating styles once at startup and referencing them by ID rather than recreating objects on each render.
3Which property to use to center an element both horizontally AND vertically within its container?
Which property to use to center an element both horizontally AND vertically within its container?
Antwoord
To center an element in both axes, combine justifyContent: 'center' (main axis) and alignItems: 'center' (cross axis). With the default flexDirection ('column'), justifyContent centers vertically and alignItems centers horizontally. These two properties work together to achieve perfect centering.
What is the default unit of measurement used in React Native for dimensions?
Which property allows positioning an element absolutely relative to its parent?
+15 gespreksvragen
Andere React Native-sollicitatieonderwerpen
JavaScript Essentials
React Fundamentals
React Native Basics
React Hooks
TypeScript for React & React Native
React Native Components & API
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
Beheers React Native voor je volgende gesprek
Krijg toegang tot alle vragen, flashcards, technische tests, code review-oefeningen en gespreksimulatoren.
Begin gratis