@tthr/vue 0.0.12 → 0.0.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -251,8 +251,11 @@ async function handleCreateComment(postId: string) {
|
|
|
251
251
|
|
|
252
252
|
try {
|
|
253
253
|
await createComment.mutate({
|
|
254
|
+
id: crypto.randomUUID(),
|
|
254
255
|
postId,
|
|
255
256
|
content: newCommentText.value.trim(),
|
|
257
|
+
authorId: 'demo-user',
|
|
258
|
+
createdAt: new Date().toISOString(),
|
|
256
259
|
});
|
|
257
260
|
newCommentText.value = '';
|
|
258
261
|
// Refresh comments for this post
|
|
@@ -295,8 +298,12 @@ async function handleCreatePost() {
|
|
|
295
298
|
|
|
296
299
|
try {
|
|
297
300
|
await createPost.mutate({
|
|
301
|
+
id: crypto.randomUUID(),
|
|
298
302
|
title: newPostTitle.value.trim(),
|
|
299
303
|
content: '',
|
|
304
|
+
authorId: 'demo-user',
|
|
305
|
+
createdAt: new Date().toISOString(),
|
|
306
|
+
updatedAt: new Date().toISOString(),
|
|
300
307
|
});
|
|
301
308
|
newPostTitle.value = '';
|
|
302
309
|
await posts.refetch();
|