diff --git a/JokesApp/redux/store.ts b/JokesApp/redux/store.ts index 28eabdb..746f93b 100644 --- a/JokesApp/redux/store.ts +++ b/JokesApp/redux/store.ts @@ -9,7 +9,8 @@ const reducer = { // @ts-ignore const store = configureStore({ - reducer: reducer, + // @ts-ignore + reducer, middleware: (getDefaultMiddleware) => getDefaultMiddleware({ serializableCheck: false diff --git a/JokesApp/screens/AccueilScreen.tsx b/JokesApp/screens/AccueilScreen.tsx index 339e8b3..5dccc3c 100644 --- a/JokesApp/screens/AccueilScreen.tsx +++ b/JokesApp/screens/AccueilScreen.tsx @@ -21,11 +21,13 @@ export function AccueilScreen() { useEffect(() => { const getJokes = async () => { + // @ts-ignore dispatch(setRecentJokes(await getLatestJokes())); }; getJokes(); const getTopCategories = async () => { + // @ts-ignore dispatch(setCategories(await getCategorie())); }; getTopCategories(); diff --git a/JokesApp/screens/ListJokeScreen.tsx b/JokesApp/screens/ListJokeScreen.tsx index b12bbc4..c61b97c 100644 --- a/JokesApp/screens/ListJokeScreen.tsx +++ b/JokesApp/screens/ListJokeScreen.tsx @@ -13,6 +13,7 @@ export function ListJokeScreen() { const dispatch = useDispatch(); useEffect(() => { const getJokes = async () => { + // @ts-ignore dispatch(setSample(await getSampleJoke())); }; getJokes();