feat: add s3 localstack, upload api
This commit is contained in:
@@ -8,6 +8,7 @@ import { create } from "zustand";
|
||||
type State = {
|
||||
data: {
|
||||
id: string;
|
||||
timestamp: number;
|
||||
json: {
|
||||
event: string;
|
||||
data: any;
|
||||
@@ -27,7 +28,7 @@ export const useStore = create<State>((set) => ({
|
||||
addData: (id, json) =>
|
||||
set((state) => ({
|
||||
...state,
|
||||
data: [...state.data, { id, json }],
|
||||
data: [...state.data, { id, json, timestamp: Date.now() }],
|
||||
})),
|
||||
}));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user