Open lovegaoshi opened 1 month ago
Thank you for your bug report. We will review it and get back to you if we need more information.
@lovegaoshi on js side we already have a property indicating if it is a local file (isAsset if I remember well). It would be easier to use this one !
This issue is stale because it has been open for 30 days with no activity. If there won't be any activity in the next 14 days, this issue will be closed automatically.
Version
6.7.0
What platforms are you having the problem on?
Android
System Version
any
On what device are you experiencing the issue?
Real device, Simulator
Architecture
Old architecture
What happened?
loaded resource
require("./asset/path")
will fail to load in production when cache enables. this is because with cache enabled, RNV will attempt to load resources as http and a local res URI will be a malformed URI.one solution could be an isUriLocalFile function, and use DefaultDataSource accordingly instead of http.
logs:
Reproduction Link
the example app
Reproduction
run the example app in production with cache on, and load the local file