-
Notifications
You must be signed in to change notification settings - Fork 121
Closed
Labels
bugSomething isn't workingSomething isn't workingruntimeThe issue or pull request is related to `runtime` packageThe issue or pull request is related to `runtime` package
Description
Describe the bug
File extension .ts is required in nuxt.config.ts serverMiddleware
To Reproduce
Steps to reproduce the behavior:
- Create a nuxt typerscript project
- Create a file
server/middleware.ts - Set it to nuxt.config.ts like
{
serverMiddleware: [
'~/server/middleware' // without extension
]
}
- Build with
node ./node_modules/\@nuxt/typescript-runtime/bin/nuxt-ts.js build - Start with
node ./node_modules/\@nuxt/typescript-runtime/bin/nuxt-ts.js start - See error
Error: Cannot find module '~/server/middleware'
Expected behavior
This should work
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingruntimeThe issue or pull request is related to `runtime` packageThe issue or pull request is related to `runtime` package