React Native Bundler Bug?
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- C++
- Star
- 127k
- Fork
- 25.3k
- Merge trung bình
- 1 ngày 23 giờ
- Pull request đã merge (30 ngày)
- 4
Mô tả
Description
I'm not sure what's going on. I spent the afternoon trying to figure out how to run a new React Native project at version 0.78.0. I simply created a new project using the following command:
npx @react-native-community/cli@17.0.0 init AwesomeProject --version 0.78.0
The project was created, and I was able to build it successfully. However, as soon as I ran the Metro bundler, the app displayed a black screen. I had to manually close the app and reopen it for anything to appear.
Steps to reproduce
- First init a new project with
npx @react-native-community/cli@17.0.0 init AwesomeProject --version 0.78.0 - Run npm run android && npm run start
- Await it to build, as soon as the app run close it, and open again manually.
React Native Version
0.78.0
Output of npx @react-native-community/cli info
System:
OS: Linux 6.8 Ubuntu 24.04.2 LTS 24.04.2 LTS (Noble Numbat)
CPU: (4) x64 Intel(R) Core(TM) i5-6500 CPU @ 3.20GHz
Memory: 11.77 GB / 31.28 GB
Shell:
version: 5.2.21
path: /bin/bash
Binaries:
Node:
version: 18.18.0
path: ~/.nvm/versions/node/v18.18.0/bin/node
Yarn:
version: 1.22.19
path: /usr/bin/yarn
npm:
version: 10.8.3
path: ~/.nvm/versions/node/v18.18.0/bin/npm
Watchman:
version: 20231224.093142.0
path: /usr/local/bin/watchman
SDKs:
Android SDK:
API Levels:
- "26"
- "27"
- "28"
- "29"
- "30"
- "31"
- "32"
- "33"
- "34"
- "35"
Build Tools:
- 28.0.3
- 30.0.2
- 30.0.3
- 31.0.0
- 32.0.0
- 33.0.0
- 33.0.1
- 34.0.0
- 35.0.0
- 35.0.1
System Images:
- android-26 | Intel x86 Atom
- android-26 | Intel x86 Atom_64
- android-26 | Google APIs Intel x86 Atom_64
- android-27 | Intel x86 Atom
- android-27 | Intel x86 Atom_64
- android-28 | Intel x86 Atom
- android-28 | Intel x86 Atom_64
- android-28 | Google Play Intel x86 Atom
- android-28 | Google Play Intel x86 Atom_64
- android-35 | Google APIs Intel x86_64 Atom
Android NDK: Not Found
IDEs:
Android Studio: Not Found
Languages:
Java:
version: 11.0.26
path: /usr/bin/javac
Ruby:
version: 3.2.3
path: /usr/bin/ruby
npmPackages:
"@react-native-community/cli":
installed: 15.0.1
wanted: 15.0.1
react:
installed: 19.0.0
wanted: 19.0.0
react-native:
installed: 0.78.0
wanted: 0.78.0
npmGlobalPackages:
"*react-native*": Not Found
Android:
hermesEnabled: true
newArchEnabled: true
iOS:
hermesEnabled: Not found
newArchEnabled: false
Screenshots and Videos
No response
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Tái hiện vấn đề bằng cách tạo React Native 0.78.0 với lệnh CLI đã nêu, sau đó chạy npm run android npm run start trong môi trường Android được báo cáo. Bắt đầu bằng cách truy vết đường dẫn khởi động của Metro bundler và so sánh lần khởi chạy đầu tiên với việc mở lại ứng dụng. Được xem là hoàn tất khi ứng dụng vừa build hiển thị bình thường ngay trong lần khởi chạy đầu tiên mà không cần đóng và mở lại ứng dụng theo cách thủ công.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- android, javascript, react-native
- Lĩnh vực
- build-system, mobile
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Sôi nổi
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 48/100