Access the store from the DataProvider within a component to retrieve data.
Example
conststore = useData()
Remarks
Use the store in a useEffect hook to retrieve the data you need and save it
to a local state (if required)
Example
useEffect(() => { if (store) { store.get<WellboreHeader>('wellbore-headers', id).then(response=> { ... // do something with the data }) } }, [store, id])
Access the store from the
DataProvider
within a component to retrieve data.Example
Remarks
Use the store in a
useEffect
hook to retrieve the data you need and save it to a local state (if required)Example
See
Data