@@ -53,7 +53,7 @@ DATABASE_URL=file:./db.sqlite
5353`
5454
5555const prismaExampleEndpoint = `/**
56- * Fetch all \`examples\` from the database. Run \`npx prisma generate\` and \`npx prisma db push\` for this to work.
56+ * Fetch all \`examples\` from the database. Run \`npx prisma db push\` at least once for this to work.
5757 *
5858 * If you are using \`tRPC\` you can access the prisma-client by adding it to the context:
5959 * \`\`\`ts
@@ -111,21 +111,12 @@ export const resetDatabase = (databaseUrl?: string) => {
111111`
112112
113113const prismaExamplePage = `<script setup lang="ts">
114- /**
115- * In Nuxt 3.1.2 \`useFetch\` return types are not correctly inferred. In order to workaround this limitation, we sadly need to manually import and type a lof ot things.
116- *
117- * As soon as https://github.com/nuxt/nuxt/issues/15280 is closed and released, we can go back to just: \`const { data: examples } = useFetch('/api/examples')\`
118- * */
119- import type { Ref } from 'vue'
120- import { Example } from '.prisma/client'
121-
122- const { data } = useFetch('/api/examples')
123- const examples = (data as Ref<Example[] | null>)
114+ const { data: examples } = useFetch('/api/examples')
124115</script>
125116
126117<template>
127118 <div>
128- <p> Prisma ORM Data from the database, received {{ examples?.length || 0 }} records: <pre>{{ examples }}</pre></p >
119+ Prisma ORM Data from the database, received {{ examples?.length || 0 }} records: <pre>{{ examples }}</pre>
129120 </div>
130121</template>
131122`
@@ -315,7 +306,7 @@ const hello = await $client.hello.useQuery({ text: 'client' })
315306<template>
316307 <div>
317308 <!-- As \`superjson\` is already pre-configured, we can use \`time\` as a \`Date\` object without further deserialization 🎉 -->
318- <p> tRPC Data: "{{ hello.data.value?.greeting }}" send at "{{ hello.data.value?.time.toLocaleDateString() }}".</p>
309+ tRPC Data: "{{ hello.data.value?.greeting }}" send at "{{ hello.data.value?.time.toLocaleDateString('en-EN' ) }}".
319310 </div>
320311</template>
321312`
@@ -348,12 +339,12 @@ export const moduleConfigs: Record<Modules, ModuleConfig> = {
348339 dependencies : [
349340 {
350341 name : "prisma" ,
351- version : "^4.8.0 " ,
342+ version : "^4.10.1 " ,
352343 isDev : true
353344 } ,
354345 {
355346 name : "@prisma/client" ,
356- version : "^4.8.0 " ,
347+ version : "^4.10.1 " ,
357348 isDev : false
358349 }
359350 ] ,
@@ -379,8 +370,7 @@ export const moduleConfigs: Record<Modules, ModuleConfig> = {
379370 } ] ,
380371 tasksPostInstall : [
381372 "- [ ] Prisma: Edit your `prisma/prisma.schema` to your liking" ,
382- "- [ ] Prisma: Run `npx prisma db push` to sync the schema to your database after changing the schema" ,
383- "- [ ] Prisma: Run `npx prisma generate` to re-generate the client after changing the schema"
373+ "- [ ] Prisma: Run `npx prisma db push` to sync the schema to your database & generate the Prisma Client" ,
384374 ] ,
385375 indexVue : generateModuleHTMLSnippet (
386376 "Prisma ORM" ,
@@ -396,9 +386,14 @@ export const moduleConfigs: Record<Modules, ModuleConfig> = {
396386 dependencies : [
397387 {
398388 name : "@sidebase/nuxt-auth" ,
399- version : "^0.3.3 " ,
389+ version : "^0.4.1 " ,
400390 isDev : true
401391 } ,
392+ {
393+ name : "next-auth" ,
394+ version : "^4.18.8" ,
395+ isDev : false
396+ }
402397 ] ,
403398 nuxtConfig : {
404399 modules : [ "@sidebase/nuxt-auth" ]
@@ -427,23 +422,23 @@ export const moduleConfigs: Record<Modules, ModuleConfig> = {
427422 description : "Build end-to-end typesafe APIs in Nuxt applications. See more: https://trpc.io/" ,
428423 dependencies : [ {
429424 name : "@trpc/server" ,
430- version : "^10.5 .0" ,
425+ version : "^10.10 .0" ,
431426 isDev : false
432427 } , {
433428 name : "@trpc/client" ,
434- version : "^10.5 .0" ,
429+ version : "^10.10 .0" ,
435430 isDev : false
436431 } , {
437432 name : "trpc-nuxt" ,
438- version : "^0.4.4 " ,
433+ version : "^0.6.0 " ,
439434 isDev : false
440435 } , {
441436 name : "zod" ,
442- version : "^3.20.2 " ,
437+ version : "^3.20.6 " ,
443438 isDev : false
444439 } , {
445440 name : "superjson" ,
446- version : "^1.12.1 " ,
441+ version : "^1.12.2 " ,
447442 isDev : false
448443 } ] ,
449444 nuxtConfig : {
@@ -512,7 +507,7 @@ export const moduleConfigs: Record<Modules, ModuleConfig> = {
512507 description : "A Vue 3 Component Library. Complete, Customizable, Uses TypeScript, Fast. See more: https://www.naiveui.com/" ,
513508 dependencies : [ {
514509 name : "@huntersofbook/naive-ui-nuxt" ,
515- version : "^0.5.1 " ,
510+ version : "^0.6.0 " ,
516511 isDev : true
517512 } ] ,
518513 nuxtConfig : {
0 commit comments