feat: version 1.0.0 (#21)

This commit is contained in:
Arash
2023-09-20 19:47:07 +03:00
committed by GitHub
parent 033380e051
commit 431d3784fe
42 changed files with 3654 additions and 3219 deletions

View File

@ -1 +1 @@
MONGODB_URI="mongodb://127.0.0.1:27017/nuxt-mongoose"
MONGODB_URI="mongodb://localhost:27017/nuxt-mongoose"

View File

@ -1,6 +1,33 @@
import { resolve } from 'node:path'
import { defineNuxtConfig } from 'nuxt/config'
import { defineNuxtModule } from '@nuxt/kit'
import { startSubprocess } from '@nuxt/devtools-kit'
import { CLIENT_PORT } from '../src/constants'
export default defineNuxtConfig({
devtools: {
enabled: true,
},
modules: [
'@nuxt/devtools',
'../src/module',
defineNuxtModule({
setup(_, nuxt) {
if (!nuxt.options.dev)
return
startSubprocess(
{
command: 'npx',
args: ['nuxi', 'dev', '--port', CLIENT_PORT.toString()],
cwd: resolve(__dirname, '../client'),
},
{
id: 'nuxt-mongoose:client',
name: 'Nuxt Mongoose Client Dev',
},
)
},
}),
],
})

View File

@ -0,0 +1,5 @@
export default defineEventHandler(async () => {
return {
message: 'hi',
}
})

View File

@ -0,0 +1,3 @@
{
"extends": "../.nuxt/tsconfig.server.json"
}