2020-10-30 22:18:17 +03:00
|
|
|
app Conduit {
|
|
|
|
title: "Conduit"
|
2020-10-30 18:28:50 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
route "/" -> page Main
|
|
|
|
page Main {
|
|
|
|
component: import Main from "@ext/MainPage.js"
|
|
|
|
}
|
2020-10-30 22:18:17 +03:00
|
|
|
|
|
|
|
route "/login" -> page Login
|
|
|
|
page Login {
|
|
|
|
component: import Login from "@ext/LoginPage.js"
|
|
|
|
}
|
|
|
|
|
|
|
|
route "/register" -> page Signup
|
|
|
|
page Signup {
|
|
|
|
component: import Signup from "@ext/SignupPage.js"
|
|
|
|
}
|
|
|
|
|
2020-11-19 17:11:23 +03:00
|
|
|
route "/settings" -> page UserSettings
|
|
|
|
page UserSettings {
|
|
|
|
component: import UserSettings from "@ext/UserSettingsPage.js"
|
|
|
|
}
|
|
|
|
|
|
|
|
route "/@:username" -> page UserProfile
|
|
|
|
page UserProfile {
|
|
|
|
component: import UserProfile from "@ext/UserProfilePage.js"
|
|
|
|
}
|
|
|
|
|
2020-10-30 22:18:17 +03:00
|
|
|
entity User {=psl
|
|
|
|
id Int @id @default(autoincrement())
|
|
|
|
username String @unique
|
|
|
|
email String @unique
|
|
|
|
password String
|
2020-11-19 17:11:23 +03:00
|
|
|
bio String?
|
|
|
|
profilePictureUrl String?
|
2020-10-30 22:18:17 +03:00
|
|
|
psl=}
|
|
|
|
|
|
|
|
auth {
|
|
|
|
userEntity: User,
|
|
|
|
methods: [ EmailAndPassword ]
|
|
|
|
}
|
|
|
|
|
|
|
|
action signup {
|
|
|
|
fn: import { signup } from "@ext/actions.js",
|
|
|
|
entities: [User]
|
2020-11-19 17:11:23 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
action updateUser {
|
|
|
|
fn: import { updateUser } from "@ext/actions.js",
|
|
|
|
entities: [User]
|
|
|
|
}
|
|
|
|
|
|
|
|
query getUser {
|
|
|
|
fn: import { getUser } from "@ext/queries.js",
|
|
|
|
entities: [User]
|
2020-10-30 22:18:17 +03:00
|
|
|
}
|