Working data and basic demo pages

This commit is contained in:
2024-05-10 00:28:23 +03:00
parent e2d2599a95
commit 9983720bd1
21 changed files with 415 additions and 91 deletions
+13 -7
View File
@@ -1,21 +1,27 @@
export type Result<T> = {[id: number]: T};
export type User = {
name: string
id: number,
name: string,
join_date: Date
};
export type Rating = {
likes: number,
dislikes: number
likes: BigInt,
dislikes: BigInt
}
export type Category = {
id: number,
name: string
}
export type Post = {
// author: User,
id: number,
author: User | null,
name: string,
// category: Category,
category: Category,
content: string,
// post_date: Date,
// rating: Rating
post_date: Date,
rating: Rating
};
+4
View File
@@ -0,0 +1,4 @@
export type Error = {
error: boolean,
msg: string
};