For the ones interested, i got an answer with the AI by retrieving data from fetch into a 'useState' local storage and by using useEffect function:
const PostScreen = () => { const [Posts, setData] = useState(null); useEffect(() => { const fetchData = async () => { try { const response = await fetch("http://192.168.0.12:8085" + "/Posts_to_App", {headers: { "content-type": "application/json" }}); const result = await response.json(); setData(result); } catch (error) { console.error('Erreur lors de la récupération des données:', error); } }; fetchData(); }, []);
Regards