I execute a query to a json file through the fetch function and in the emulator the result is immediate, it takes a century on the real device (motorola one vision) to give results.
What can it be? I isolated the code in a project from scratch to see and the problem really is in the type of query.
Could it be some gradlew configuration when generating the APK?
Thank you in advance!
import React, { useState } from 'react';import { View, Text, ActivityIndicator} from 'react-native';export default () => { const [status, setStatus] = useState(false); fetch('https://senhor.app/trilhas/restaurantes.json').then(data => setStatus(true)); return (<View style={{ flex: 1, alignItems: 'center', justifyContent: 'center' }}><Text>Funcional</Text> { status ? <Text>Carregou</Text> : <ActivityIndicator size="large" color="#00ff00" /> }</View> );}