mirror of
https://github.com/nuxt/nuxt.git
synced 2025-01-22 11:22:43 +00:00
fix: missing name in nuxt object
This commit is contained in:
parent
d7946f92ac
commit
e872a19dae
@ -51,7 +51,7 @@ import { randomUUID } from 'node:crypto'
|
|||||||
|
|
||||||
export function createNuxt (options: NuxtOptions): Nuxt {
|
export function createNuxt (options: NuxtOptions): Nuxt {
|
||||||
const hooks = createHooks<NuxtHooks>()
|
const hooks = createHooks<NuxtHooks>()
|
||||||
const name = randomUUID()
|
const name = randomUUID() // TODO find project name in package json instead
|
||||||
const nuxt: Nuxt = {
|
const nuxt: Nuxt = {
|
||||||
_version: version,
|
_version: version,
|
||||||
options,
|
options,
|
||||||
@ -63,6 +63,7 @@ export function createNuxt (options: NuxtOptions): Nuxt {
|
|||||||
close: () => hooks.callHook('close', nuxt),
|
close: () => hooks.callHook('close', nuxt),
|
||||||
vfs: {},
|
vfs: {},
|
||||||
apps: {},
|
apps: {},
|
||||||
|
name
|
||||||
}
|
}
|
||||||
|
|
||||||
hooks.hookOnce('close', () => { hooks.removeAllHooks() })
|
hooks.hookOnce('close', () => { hooks.removeAllHooks() })
|
||||||
|
Loading…
Reference in New Issue
Block a user