lesson 4 live 30/12

This commit is contained in:
2023-12-30 19:18:54 +01:00
parent 7adcc8d2c9
commit b81d33c1b4
14 changed files with 243 additions and 24 deletions

View File

@@ -1,14 +1,9 @@
import { createApi, fetchBaseQuery } from '@reduxjs/toolkit/query/react'
import { baseQueryWithReauth } from '@/services/base-query-with-reauth'
import { createApi } from '@reduxjs/toolkit/query/react'
export const baseApi = createApi({
baseQuery: fetchBaseQuery({
baseUrl: 'https://api.flashcards.andrii.es',
credentials: 'include',
prepareHeaders: headers => {
headers.append('x-auth-skip', 'true')
},
}),
baseQuery: baseQueryWithReauth,
endpoints: () => ({}),
reducerPath: 'baseApi',
tagTypes: ['Decks'],
tagTypes: ['Decks', 'Me'],
})