Repository: next.js
Issue: Erorrs on create-next-app initialization
Labels: Upstream,bug

### Verify canary release

- [X] I verified that the issue exists in the latest Next.js canary release

### Provide environment information

```bash
Operating System:
      Platform: win32
      Arch: x64
      Version: Windows 10 Home
    Binaries:
      Node: 18.16.0
      npm: N/A
      Yarn: N/A
      pnpm: N/A
    Relevant packages:
      next: 13.4.6
      eslint-config-next: N/A
      react: 18.2.0
      react-dom: 18.2.0
      typescript: N/A
```


### Which area(s) of Next.js are affected? (leave empty if unsure)

_No response_

### Link to the code that reproduces this issue or a replay of the bug

https://codesandbox.io/p/sandbox/github/vercel/next.js/tree/canary/examples/reproduction-template

### To Reproduce

**the code is just the provided. ANY change was made to original code that comes with create-next-app install**

tested on:
- OS Windows 10
- node versions: 18.16.0  (lts at this time), 16.14.2
-  browsers: Chrome 114.0.5735.134, Edge   114.0.1823.43

commands used:
```
npx create-next-app@latest mysite
cd mysite
npm run dev
```
or  (with  create-next-app@13.4.7-canary.0)
```
npx create-next-app@canary mywebsite
cd mysite
npm run dev
```

on both, options were:
```
Need to install the following packages:
Ok to proceed? (y)
√ Would you like to use TypeScript with this project? ... No / 
√ Would you like to use ESLint with this project? ... No / 
√ Would you like to use Tailwind CSS with this project? ... / Yes
√ Would you like to use `src/` directory with this project? ... / Yes
√ Use App Router (recommended)? ... / Yes
√ Would you like to customize the default import alias? ... No / 
Creating a new Next.js app in D:\mywebsite.

Using npm.

Initializing project with template: app-tw


Installing dependencies:
- react
- react-dom
- next
- tailwindcss
- postcss
- autoprefixer
```


the code is just the provided. ANY change was made to original code that comes with create-next-app install

### Describe the Bug

When running **npm run dev** I get this big errors/warnings in console:
The part: There are multiple modules.... repeates at least 30 times more (I hidded due limits on writing issue here)

```> dev
> next dev
- ready started server on 0.0.0.0:3000, url: http://localhost:3000
- event compiled client and server successfully in 142 ms (18 modules)
- wait compiling /_error (client and server)...
- wait compiling / (client and server)...
- warn ./node_modules/next/dist/client/add-base-path.js
There are multiple modules with names that only differ in casing.
This can lead to unexpected behavior when compiling on a filesystem with other case-semantic.
Use equal casing. Compare these module identifiers:
* D:\mysite\node_modules\next\dist\compiled\@next\react-refresh-utils\dist\loader.js!D:\mysite\node_modules\next\dist\build\webpack\loaders\next-swc-loader.js??ruleSet[1].rules[1].oneOf[2].use[1]!D:\mysite\node_modules\next\dist\client\add-base-path.js
    Used by 2 module(s), i. e.
    D:\mysite\node_modules\next\dist\compiled\@next\react-refresh-utils\dist\loader.js!D:\mysite\node_modules\next\dist\build\webpack\loaders\next-swc-loader.js??ruleSet[1].rules[1].oneOf[2].use[1]!D:\mysite\node_modules\next\dist\shared\lib\router\router.js
* D:\mysite\node_modules\next\dist\compiled\@next\react-refresh-utils\dist\loader.js!D:\mysite\node_modules\next\dist\build\webpack\loaders\next-swc-loader.js??ruleSet[1].rules[1].oneOf[2].use[1]!D:\mysite\node_modules\next\dist\client\add-base-path.js
    Used by 3 module(s), i. e.
    D:\mysite\node_modules\next\dist\compiled\@next\react-refresh-utils\dist\loader.js!D:\mysite\node_modules\next\dist\build\webpack\loaders\next-swc-loader.js??ruleSet[1].rules[1].oneOf[2].use[1]!D:\mysite\node_modules\next\dist\client\page-loader.js

Import trace for requested module:
./node_modules/next/dist/client/add-base-path.js
./node_modules/next/dist/shared/lib/router/router.js

./node_modules/next/dist/client/add-locale.js
There are multiple modules with names that only differ in casing.
This can lead to unexpected behavior when compiling on a filesystem with other case-semantic.
Use equal casing. Compare these module identifiers:
* D:\mysite\node_modules\next\dist\compiled\@next\react-refresh-utils\dist\loader.js!D:\mysite\node_modules\next\dist\build\webpack\loaders\next-swc-loader.js??ruleSet[1].rules[1].oneOf[2].use[1]!D:\mysite\node_modules\next\dist\client\add-locale.js
    Used by 2 module(s), i. e.
    D:\mysite\node_modules\next\dist\compiled\@next\react-refresh-utils\dist\loader.js!D:\mysite\node_modules\next\dist\build\webpack\loaders\next-swc-loader.js??ruleSet[1].rules[1].oneOf[2].use[1]!D:\mysite\node_modules\next\dist\shared\lib\router\router.js
* D:\mysite\node_modules\next\dist\compiled\@next\react-refresh-utils\dist\loader.js!D:\mysite\node_modules\next\dist\build\webpack\loaders\next-swc-loader.js??ruleSet[1].rules[1].oneOf[2].use[1]!D:\mysite\node_modules\next\dist\client\add-locale.js
    Used by 3 module(s), i. e.
    D:\mysite\node_modules\next\dist\compiled\@next\react-refresh-utils\dist\loader.js!D:\mysite\node_modules\next\dist\build\webpack\loaders\next-swc-loader.js??ruleSet[1].rules[1].oneOf[2].use[1]!D:\mysite\node_modules\next\dist\client\page-loader.js

There are multiple modules with names that only differ in casing.
This can lead to unexpected behavior when compiling on a filesystem with other case-semantic.
Use equal casing. Compare these module identifiers:
* D:\mysite\node_modules\next\dist\build\webpack\loaders\next-swc-loader.js??ruleSet[1].rules[1].oneOf[2].use!D:\mysite\node_modules\next\dist\shared\lib\head.js
    Used by 3 module(s), i. e.
    D:\mysite\node_modules\next\dist\build\webpack\loaders\next-swc-loader.js??ruleSet[1].rules[1].oneOf[2].use!D:\mysite\node_modules\next\dist\pages\_error.js
* D:\mysite\node_modules\next\dist\build\webpack\loaders\next-swc-loader.js??ruleSet[1].rules[1].oneOf[2].use!D:\mysite\node_modules\next\dist\shared\lib\head.js
    Used by 2 module(s), i. e.
    D:\mysite\node_modules\next\dist\build\webpack\loaders\next-swc-loader.js??ruleSet[1].rules[1].oneOf[2].use!D:\mysite\node_modules\next\dist\pages\_error.js

Import trace for requested module:
./node_modules/next/dist/shared/lib/head.js
./node_modules/next/dist/pages/_error.js
Warning: Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:
1. You might have mismatching versions of React and the renderer (such as React DOM)
2. You might be breaking the Rules of Hooks
3. You might have more than one copy of React in the same app
See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.
TypeError: Cannot read properties of null (reading 'useContext')
    at useContext (D:\mysite\node_modules\react\cjs\react.development.js:1618:21)
    at Head (webpack-internal:///./node_modules/next/dist/shared/lib/head.js?04f70:149:44)
    at renderWithHooks (D:\mysite\node_modules\react-dom\cjs\react-dom-server.browser.development.js:5658:16)
    at renderIndeterminateComponent (D:\mysite\node_modules\react-dom\cjs\react-dom-server.browser.development.js:5731:15)
    
    at renderToString (D:\mysite\node_modules\next\dist\server\render.js:82:55)
    at D:\mysite\node_modules\next\dist\server\render.js:914:112
    at NextTracerImpl.trace (D:\mysite\node_modules\next\dist\server\lib\trace\tracer.js:90:20)
    1. You might have mismatching versions of React and the renderer (such as React DOM)
    2. You might be breaking the Rules of Hooks
    3. You might have more than one copy of React in the same app
    See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.
    - error TypeError: Cannot read properties of null (reading 'useContext')
```

PS: npm run build shows same errors
PS2: npm run start shows: errors:
```
next start

- ready started server on 0.0.0.0:3000, url: http://localhost:3000
Error: Cannot find module 'D:\mywebsite\.next\prerender-manifest.json'
Require stack:
- D:\mywebsite\node_modules\next\dist\server\next-server.js
- D:\mywebsite\node_modules\next\dist\server\next.js
- D:\mywebsite\node_modules\next\dist\server\lib\render-server.js
- D:\mywebsite\node_modules\next\dist\compiled\jest-worker\processChild.js
    at Module._resolveFilename (node:internal/modules/cjs/loader:1075:15)
    at D:\mywebsite\node_modules\next\dist\server\require-hook.js:189:36
    at Module._load (node:internal/modules/cjs/loader:920:27)
    at Module.require (node:internal/modules/cjs/loader:1141:19)
    at require (node:internal/modules/cjs/helpers:110:18)
    at NextNodeServer.getPrerenderManifest (D:\mywebsite\node_modules\next\dist\server\next-server.js:1927:26)
    at new Server (D:\mywebsite\node_modules\next\dist\server\base-server.js:170:32)
    at new NextNodeServer (D:\mywebsite\node_modules\next\dist\server\next-server.js:173:9)
    at NextServer.createServer (D:\mywebsite\node_modules\next\dist\server\next.js:179:24)
    at async D:\mywebsite\node_modules\next\dist\server\next.js:200:31 {
  type: 'Error',
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    'D:\\mywebsite\\node_modules\\next\\dist\\server\\next-server.js',
    'D:\\mywebsite\\node_modules\\next\\dist\\server\\next.js',
    'D:\\mywebsite\\node_modules\\next\\dist\\server\\lib\\render-server.js',
    'D:\\mywebsite\\node_modules\\next\\dist\\compiled\\jest-worker\\processChild.js'
  ]
}
```
**Error occurs when browser is opened on localhost:3000 or on page refresh**

### Expected Behavior

Expected no errors, just webpage opening rightly on browser.


### Which browser are you using? (if relevant)

 Chrome 114.0.5735.134, Edge 114.0.1823.43

### How are you deploying your application? (if relevant)

no deploy