@qbit-tech/libs-react
v1.4.6
Published
``` useTrackerIndexedDB({ appName: "PROJECT_NAME", userId: user.userId, userData: user, processUpload: (activities: IActivity[], onSuccess: (ids: number[]) => void) => { httpRequest .post(process.env.REACT_APP_API_URL_TRACKME || '', { bu
Downloads
4
Keywords
Readme
How to use TrackMe
useTrackerIndexedDB({
appName: "PROJECT_NAME",
userId: user.userId,
userData: user,
processUpload: (activities: IActivity[], onSuccess: (ids: number[]) => void) => {
httpRequest
.post(process.env.REACT_APP_API_URL_TRACKME || '', { bulk: activities })
.then((res: any) => {
onSuccess((res.data.payload || []).map((item: any) => item.activityId));
})
.catch((err) => {
message.error(getErrorMessage(err));
});
},
});