@@ -141,7 +141,7 @@ export const getNotes = () =>
141141The <i >App</i > component is now slightly simplified
142142
143143``` js
144- import { useQuery } from ' react-query'
144+ import { useQuery } from ' @tanstack/ react-query'
145145import { getNotes } from ' ./requests' // highlight-line
146146
147147const App = () => {
@@ -179,7 +179,7 @@ export const createNote = newNote => // highlight-line
179179The <i >App</i > component will change as follows
180180
181181``` js
182- import { useQuery , useMutation } from ' react-query' // highlight-line
182+ import { useQuery , useMutation } from ' @tanstack/ react-query' // highlight-line
183183import { getNotes , createNote } from ' ./requests' // highlight-line
184184
185185const App = () => {
@@ -218,7 +218,7 @@ In order to render a new note as well, we need to tell React Query that the old
218218Fortunately, invalidation is easy, it can be done by defining the appropriate <i >onSuccess</i > callback function to the mutation:
219219
220220``` js
221- import { useQuery , useMutation , useQueryClient } from ' react-query' // highlight-line
221+ import { useQuery , useMutation , useQueryClient } from ' @tanstack/ react-query' // highlight-line
222222import { getNotes , createNote } from ' ./requests'
223223
224224const App = () => {
@@ -253,7 +253,7 @@ export const updateNote = updatedNote =>
253253Updating the note is also done by mutation. The <i >App</i > component expands as follows:
254254
255255``` js
256- import { useQuery , useMutation , useQueryClient } from ' react-query'
256+ import { useQuery , useMutation , useQueryClient } from ' @tanstack/ react-query'
257257import { getNotes , createNote , updateNote } from ' ./requests' // highlight-line
258258
259259const App = () => {
0 commit comments