expo/examples

Error running npx create-react-native-app -t with-nextjs

tomsoderlund opened this issue ยท 0 comments

Describe the bug
Getting UnhandledPromiseRejectionWarning: Error: Cannot find module '/Users/USERNAME/Documents/Development/Projects/Templates/expo-nextjs/node_modules/react-native-scripts/build/scripts/init.js'

To Reproduce
npx create-react-native-app -t with-nextjs expo-nextjs
Creating a new React Native app in /Users/USERNAME/Documents/Development/Projects/Templates/expo-nextjs.

Using package manager as yarnpkg with yarn interface.
Installing packages. This might take a couple minutes.
Installing react-native-scripts...

yarn add v1.22.19
info No lockfile found.
[1/4] ๐Ÿ”  Resolving packages...
warning react-native-scripts > babel-runtime > core-js@2.6.12: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.
[2/4] ๐Ÿšš  Fetching packages...
[3/4] ๐Ÿ”—  Linking dependencies...
[4/4] ๐Ÿ”จ  Building fresh packages...
success Saved lockfile.
success Saved 20 new dependencies.
info Direct dependencies
โ””โ”€ react-native-scripts@2.0.1
info All dependencies
โ”œโ”€ ansi-styles@3.2.1
โ”œโ”€ babel-runtime@6.26.0
โ”œโ”€ chalk@2.4.2
โ”œโ”€ color-convert@1.9.3
โ”œโ”€ color-name@1.1.3
โ”œโ”€ core-js@2.6.12
โ”œโ”€ cross-spawn@5.1.0
โ”œโ”€ escape-string-regexp@1.0.5
โ”œโ”€ has-flag@3.0.0
โ”œโ”€ isexe@2.0.0
โ”œโ”€ lru-cache@4.1.5
โ”œโ”€ minimist@1.2.7
โ”œโ”€ pseudomap@1.0.2
โ”œโ”€ react-native-scripts@2.0.1
โ”œโ”€ regenerator-runtime@0.11.1
โ”œโ”€ shebang-command@1.2.0
โ”œโ”€ shebang-regex@1.0.0
โ”œโ”€ supports-color@5.5.0
โ”œโ”€ which@1.3.1
โ””โ”€ yallist@2.1.2
โœจ  Done in 4.25s.
(node:53350) UnhandledPromiseRejectionWarning: Error: Cannot find module '/Users/USERNAME/Documents/Development/Projects/Templates/expo-nextjs/node_modules/react-native-scripts/build/scripts/init.js'
Require stack:
- /Users/USERNAME/.config/yarn/global/node_modules/create-react-native-app/build/index.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
    at Function.Module._load (internal/modules/cjs/loader.js:746:27)
    at Module.require (internal/modules/cjs/loader.js:974:19)
    at require (internal/modules/cjs/helpers.js:93:18)
    at _callee2$ (/Users/USERNAME/.config/yarn/global/node_modules/create-react-native-app/build/index.js:128:32)
    at tryCatch (/Users/USERNAME/.config/yarn/global/node_modules/babel-runtime/node_modules/regenerator-runtime/runtime.js:62:40)
    at Generator.invoke [as _invoke] (/Users/USERNAME/.config/yarn/global/node_modules/babel-runtime/node_modules/regenerator-runtime/runtime.js:296:22)
    at Generator.prototype.<computed> [as next] (/Users/USERNAME/.config/yarn/global/node_modules/babel-runtime/node_modules/regenerator-runtime/runtime.js:114:21)
    at step (/Users/USERNAME/.config/yarn/global/node_modules/babel-runtime/helpers/asyncToGenerator.js:17:30)
    at /Users/USERNAME/.config/yarn/global/node_modules/babel-runtime/helpers/asyncToGenerator.js:28:13
(Use `node --trace-warnings ...` to show where the warning was created)
(node:53350) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:53350) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

Additional context

  • macOS
  • Node.js v14.18.0