What is the purpose of the LogBox in React Native?
4 phương ánCó giải thích
Các phương án trả lời
Chọn một phương ánLời giảiChọn phương án để mở
Đáp án đúng: "To show errors and warnings during development". LogBox là cơ chế hiển thị lỗi và cảnh báo có sẵn trong React Native từ bản 0.63: ở chế độ phát triển, cảnh báo (console.warn) hiện thành thông báo nhỏ ở cuối màn hình, lỗi nghiêm trọng hoặc lỗi cú pháp hiện toàn màn hình kèm stack trace, và có thể ẩn bớt bằng LogBox.ignoreLogs; nó không chạy trong bản production. "To display network requests" là việc của công cụ như Flipper hay Reactotron. "To inspect component hierarchies" là việc của React DevTools hoặc Element Inspector. "To manage application state" là vai trò của useState, Context hay Redux, không liên quan LogBox.
Cùng chương 1
Ordering steps in the process of how React Native works in Bridge architecture:
1.The main cable starts working and starts loading JavaScript loads
2.Produces a new DOM (structure) and sends changes to Shadow cable
3.If the JavaScript code is successfully uploaded, the main thread sends it to another JavaScript thread
4.Main thread is able to render something on the screen
5.The shadow string calculates the structure and sends the parameters/properties of the structure to the main sequenceCó lời giảiCâu hỏiReact Native uses the following tech stack to build cross-platform native apps:Có lời giảiCâu hỏiHow does React Native differ from React.js in terms of rendering components?Có lời giảiCâu hỏiCả 54 câu của chủ đề54 câu