You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
yarn run v1.22.17
$ next
node:internal/modules/cjs/loader:488
throw e;
^
Error: Cannot find module '/Users/kimitsu/work/using-preact-app/node_modules/react-dom/server.browser.js'
at createEsmNotFoundErr (node:internal/modules/cjs/loader:960:15)
at finalizeEsmResolution (node:internal/modules/cjs/loader:953:15)
at resolveExports (node:internal/modules/cjs/loader:482:14)
at Function.Module._findPath (node:internal/modules/cjs/loader:522:31)
at Function.Module._resolveFilename (node:internal/modules/cjs/loader:919:27)
at Function.Module._load (node:internal/modules/cjs/loader:778:27)
at Module.require (node:internal/modules/cjs/loader:1005:19)
at require (node:internal/modules/cjs/helpers:102:18)
at Object.<anonymous> (/Users/kimitsu/work/using-preact-app/node_modules/next/dist/bin/next:76:30)
at Module._compile (node:internal/modules/cjs/loader:1101:14) {
code: 'MODULE_NOT_FOUND',
path: '/Users/kimitsu/work/using-preact-app/node_modules/react-dom/package.json'
}
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
If you look at package.json, you will see that react-dom has an alias to preact/compat.
Actual react-dom has server.browser.js, but preact/compat does not.
Expected behavior
A server starts with yarn dev, and it works well
The text was updated successfully, but these errors were encountered:
Describe the bug
I cannot use Next.js with Preact, since preact/compat is missing server.browser.js.
To Reproduce
Exec following commands.
yarn create next-app --example using-preact using-preact-app
cd using-preact-app
yarn dev
Then,
If you look at package.json, you will see that react-dom has an alias to preact/compat.
Actual react-dom has server.browser.js, but preact/compat does not.
Expected behavior
A server starts with
yarn dev
, and it works wellThe text was updated successfully, but these errors were encountered: