react-native run-android无法正常工作,无法从资产加载脚本,错误:ENOSPC:设备上没有剩余空间

问题描述 投票:0回答:2

在android设备中运行app的步骤:1。cd(项目目录)2。react-native run-android

attached screenshot issue

为了解决这个问题,我使用了下面提到的命令:

1.(in project directory) mkdir android/app/src/main/assets
2. react-native bundle --platform android --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res

之后,我遇到了问题“错误:ENOSPC:设备上没有剩余空间”,附上截图。请检查一下。 issue screenshot here

android react-native react-native-android
2个回答
1
投票

试试npm cache clear

如果它不起作用,请尝试此命令。

echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p

0
投票

尝试

1. cd(directory)
2. cd android
3. gradlew clean
4. cd ..
5. react-native run-android`
© www.soinside.com 2019 - 2024. All rights reserved.