🛂(app-desk) create fetchAPI
Create a fetch wrapper for the API calls, it will handle: - add correct basename on the api request - add Bearer automatically on the api request - logout automatically on 401 request
This commit is contained in:
@@ -9,6 +9,7 @@ const createJestConfig = nextJest({
|
||||
const config: Config = {
|
||||
coverageProvider: 'v8',
|
||||
testEnvironment: 'jsdom',
|
||||
setupFilesAfterEnv: ['<rootDir>/jest.setup.ts'],
|
||||
};
|
||||
|
||||
// createJestConfig is exported this way to ensure that next/jest can load the Next.js config which is async
|
||||
|
||||
Reference in New Issue
Block a user