This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
Logic to refresh token automatically without showing error to our users | |
*/ | |
axiosInstance.interceptors.response.use( | |
(response: AxiosResponse) => { | |
return response; | |
}, | |
(error: AxiosError) => { | |
if ( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Using commonjs js modules | |
import utils from './services/utils'; | |
let array = [[1,2,[3]],4]; | |
let newArray = utils.flat(array); | |
console.log(newArray); |