// services/api.js // Export par défaut : le client API principal const apiClient = { get: (url) => fetch(url).then(r => r.json()), post: (url, data) => fetch(url, { method: 'POST', body: JSON.stringify(data) }) }; // Exports nommés : utilitaires export const API_URL = "https://api.example.com"; export const handleError = (error) => console.error(error); export default apiClient;