Hello I Converted React Native Java Script Project into Typescript all working is fine but some warning is showing me please any one help me out in this ! How to pass props from other folder please look into
import Axios from "axios"; import config from "../../config"; const axios = Axios; axios.defaults.baseURL = config.API_URL; axios.handleError = (error:any) => { //Error ---Property 'handleError' does not exist on type 'AxiosStatic'. if (error?.response?.data?.error) { console.log("handleError@@@",error?.response?.data?.error+"") } };export default axios;
i used Axios fo API call so please anyone suggest me how to use error handling in TypeScript