feat: edit and resubmit messages (#592)
This commit is contained in:
parent
2e479ccce7
commit
64d1aad2bb
12 changed files with 302 additions and 25 deletions
10
hooks/use-user-message-id.ts
Normal file
10
hooks/use-user-message-id.ts
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
'use client';
|
||||
|
||||
import useSWR from 'swr';
|
||||
|
||||
export function useUserMessageId() {
|
||||
const { data: userMessageIdFromServer, mutate: setUserMessageIdFromServer } =
|
||||
useSWR('userMessageIdFromServer', null);
|
||||
|
||||
return { userMessageIdFromServer, setUserMessageIdFromServer };
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue