feat: support replies

This commit is contained in:
Stevan Freeborn
2023-09-14 21:47:40 -05:00
parent 0dc2934e05
commit 820ba6b1e8
14 changed files with 344 additions and 97 deletions
+3 -1
View File
@@ -39,7 +39,9 @@ export default defineSchema(
parentPostId: v.optional(v.id('posts')),
userId: v.id('users'),
content: v.array(v.string()),
}).index('by_user_id', ['userId']),
})
.index('by_user_id', ['userId'])
.index('by_parent_id', ['parentPostId']),
},
{ schemaValidation: false }
);