-
-
Notifications
You must be signed in to change notification settings - Fork 113
Closed
Description
I've got an error when I upgraded to Next 15. This is the next.config.ts file I used:
import type { NextConfig } from 'next'
await import('@/env')
const config: NextConfig = {}And i just received this error:
C:\Users\Gabriel\Workspace\Proyectos\next-blog\next.config.compiled.js:53
await Promise.resolve().then(function() {
^^^^^
SyntaxError: await is only valid in async functions and the top level bodies of modules
at wrapSafe (node:internal/modules/cjs/loader:1281:20)
at Module._compile (node:internal/modules/cjs/loader:1321:27)
at requireFromString (C:\Users\Gabriel\Workspace\Proyectos\next-blog\node_modules\.pnpm\[email protected]_@[email protected]_@[email protected][email protected]_5lakrbqt32k3gsjhjvvzwqmo3u\node_modules\next\dist\build\next-config-ts\require-hook.js:81:7)
at transpileConfig (C:\Users\Gabriel\Workspace\Proyectos\next-blog\node_modules\.pnpm\[email protected]_@[email protected]_@[email protected][email protected]_5lakrbqt32k3gsjhjvvzwqmo3u\node_modules\next\dist\build\next-config-ts\transpile-config.js:63:51)
at async loadConfig (C:\Users\Gabriel\Workspace\Proyectos\next-blog\node_modules\.pnpm\[email protected]_@[email protected]_@[email protected][email protected]_5lakrbqt32k3gsjhjvvzwqmo3u\node_modules\next\dist\server\config.js:763:36)
at async Module.nextDev (C:\Users\Gabriel\Workspace\Proyectos\next-blog\node_modules\.pnpm\[email protected]_@[email protected]_@[email protected][email protected]_5lakrbqt32k3gsjhjvvzwqmo3u\node_modules\next\dist\cli\next-dev.js:189:14)
Node.js v20.15.1
ELIFECYCLE Command failed with exit code 1.
I don't know what to do...
Metadata
Metadata
Assignees
Labels
No labels