Module parse failed in react.js

Viewed 10

Failed to compile. i am having this error ./src/utils/useAxios.js 21:49 Module parse failed: Unexpected token (21:49) You may need an appropriate loader to handle this file type. | baseURL: baseURL, | headers: {

  Authorization: "Bearer ".concat(authTokens?.access) 

| } | });

within this function const axiosInstance = axios.create({ baseURL, headers: { Authorization: Bearer ${authTokens?.access} } });

how can this be resolved?

0 Answers
Related