React Native

Monorepo & Code Sharing

Yarn workspaces, nx, shared packages, React Native Web, code reuse strategies

18 питань зі співбесід·
Senior
1

What is a monorepo in the context of React Native development?

Відповідь

A monorepo is an architecture where multiple projects or packages are stored in a single Git repository. In the React Native context, this enables code sharing between a mobile app, a web app (React Native Web), and utility packages. Benefits include centralized dependency management, atomic refactoring, and code consistency across platforms.

2

What is the main role of Yarn workspaces in a React Native monorepo?

Відповідь

Yarn workspaces enable managing multiple packages in a single repository with a single hoisted node_modules at the root. This reduces dependency duplication, enables automatic symlinking between local packages, and facilitates global scripts. In a React Native monorepo, this allows automatic linking of shared packages to both mobile and web applications.

3

How to configure a basic monorepo with Yarn workspaces for React Native?

Відповідь

The basic configuration requires a root package.json with the workspaces field defining package patterns. Typically, packages/* or apps/* is used for applications and packages/* for shared libraries. The private field must be set to true to prevent accidental publication of the root package. Metro bundler also requires configuration to resolve symlinks properly.

4

What problem can dependency hoisting cause in a React Native monorepo?

5

What is Nx and what main advantage does it provide over Yarn workspaces alone?

+15 питань зі співбесід

Інші теми співбесід React Native

JavaScript Essentials

Junior
25 запитань

React Fundamentals

Junior
20 запитань

React Native Basics

Junior
22 запитань

React Hooks

Junior
20 запитань

TypeScript for React & React Native

Junior
22 запитань

React Native Components & API

Junior
20 запитань

React Native Styling & Layout

Junior
18 запитань

React Native Navigation

Mid-Level
22 запитань

React Native State Management

Mid-Level
24 запитань

React Native Networking & API

Mid-Level
20 запитань

Data Persistence

Mid-Level
20 запитань

Forms & Validation

Mid-Level
18 запитань

React Native Animations

Mid-Level
22 запитань

Native Modules & Bridge

Mid-Level
20 запитань

Platform-Specific Code

Mid-Level
18 запитань

Permissions & Device APIs

Mid-Level
20 запитань

Push Notifications

Mid-Level
18 запитань

React Native Testing

Mid-Level
20 запитань

React Native Debugging

Mid-Level
18 запитань

Build & Deployment

Mid-Level
20 запитань

Expo vs React Native Bare

Mid-Level
18 запитань

Performance Optimization

Senior
24 запитань

Memory Management

Senior
20 запитань

Architecture Patterns

Senior
22 запитань

React Native New Architecture

Senior
24 запитань

Security Best Practices

Senior
20 запитань

Offline-First Architecture

Senior
20 запитань

React Native CI/CD

Senior
20 запитань

Advanced Topics

Senior
22 запитань

App Lifecycle & Background Execution

Mid-Level
20 запитань

Authentication & Session Management

Mid-Level
22 запитань

Monitoring & Crash Reporting

Senior
20 запитань

Опануй React Native для наступної співбесіди

Отримай доступ до всіх питань, flashcards, технічних тестів, вправ code review та симуляторів співбесід.

Почни безкоштовно