add sonner + project creation working
This commit is contained in:
@ -3,13 +3,16 @@
|
||||
export async function createSandbox(body: {
|
||||
type: string
|
||||
name: string
|
||||
userId: string
|
||||
visibility: string
|
||||
}) {
|
||||
const res = await fetch("http://localhost:8787/api/sandbox/create", {
|
||||
method: "POST",
|
||||
const res = await fetch("http://localhost:8787/api/sandbox", {
|
||||
method: "PUT",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
body: JSON.stringify(body),
|
||||
})
|
||||
|
||||
return await res.text()
|
||||
}
|
||||
|
@ -11,6 +11,7 @@ export type Sandbox = {
|
||||
id: string
|
||||
name: string
|
||||
type: "react" | "node"
|
||||
visibility: "public" | "private"
|
||||
userId: string
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user