Skip to content

Commit a2cc6ba

Browse files
committed
chore(up): update module ; improve prompts handling
1 parent 9b7da2b commit a2cc6ba

5 files changed

Lines changed: 132 additions & 94 deletions

File tree

playground/dbschema/default.esdl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,13 @@ module default {
1818

1919
type BlogPost {
2020
property content: str {
21-
default := 'My blog post content.';
21+
default := 'My super blog post.';
2222
};
2323
property description: str {
2424
default := 'My blog post description.';
2525
};
2626
property title: str {
27-
default := 'My blog post';
27+
default := 'My blog super blog post title.';
2828
};
2929
required author: User {
3030
default := global current_user;

playground/nuxt.config.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,8 @@ export default defineNuxtConfig({
77
auth: true,
88
oauth: true
99
},
10-
devtools: { enabled: true }
10+
devtools: { enabled: true },
11+
tailwindcss: {
12+
viewer: false
13+
}
1114
})
Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,6 @@
11
import { defineEventHandler, isMethod, readBody } from 'h3'
22

33
export default defineEventHandler(async (req) => {
4-
if (isMethod(req, 'DELETE')) {
5-
const { id } = await readBody(req)
6-
7-
const { deleteBlogPost } = useEdgeDbQueries(req)
8-
9-
return await deleteBlogPost({ blogpost_id: id })
10-
}
114
if (isMethod(req, 'POST')) {
125
const {
136
title,
@@ -21,12 +14,9 @@ export default defineEventHandler(async (req) => {
2114
blogpost_title: title,
2215
blogpost_description: description,
2316
blogpost_content: content,
17+
2418
})
2519

2620
return blogPost
2721
}
28-
29-
const { allBlogPosts } = useEdgeDbQueries()
30-
31-
return await allBlogPosts()
3222
})

playground/tsconfig.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
{
2-
"extends": "./.nuxt/tsconfig.json"
2+
"extends": "./.nuxt/tsconfig.json",
3+
"vueCompilerOptions": {
4+
"skipTemplateCodegen": true
5+
}
36
}

0 commit comments

Comments
 (0)