1

In my React-Native project, I downloaded the react-native-camera and react-native-qrcode-scanner libraries with node to read qr code, but I started getting such an error while running the application.

node:internal/modules/cjs/loader:926 throw err; ^

Error: Cannot find module '@hapi/joi' Require stack:

  • D:\React\LCapp\LCapp\node_modules@react-native-community\cli\build\tools\config\schema.js
  • D:\React\LCapp\LCapp\node_modules@react-native-community\cli\build\tools\config\readConfigFromDisk.js
  • D:\React\LCapp\LCapp\node_modules@react-native-community\cli\build\tools\config\index.js
  • D:\React\LCapp\LCapp\node_modules@react-native-community\cli\build\commands\install\install.js
  • D:\React\LCapp\LCapp\node_modules@react-native-community\cli\build\commands\index.js
  • D:\React\LCapp\LCapp\node_modules@react-native-community\cli\build\index.js
  • D:\React\LCapp\LCapp\node_modules@react-native-community\cli\build\bin.js at Function.Module._resolveFilename (node:internal/modules/cjs/loader:923:15) at Function.Module._load (node:internal/modules/cjs/loader:768:27) at Module.require (node:internal/modules/cjs/loader:995:19) at require (node:internal/modules/cjs/helpers:92:18) at t (D:\React\LCapp\LCapp\node_modules@react-native-community\cli\build\tools\config\schema.js:9:40) at Object. (D:\React\LCapp\LCapp\node_modules@react-native-community\cli\build\tools\config\schema.js:28:17) at Module._compile (node:internal/modules/cjs/loader:1091:14) at Object.Module._extensions..js (node:internal/modules/cjs/loader:1120:10) at Module.load (node:internal/modules/cjs/loader:971:32) at Function.Module._load (node:internal/modules/cjs/loader:812:14) { code: 'MODULE_NOT_FOUND', requireStack: [ 'D:\React\LCapp\LCapp\node_modules\@react-native-community\cli\build\tools\config\schema.js', 'D:\React\LCapp\LCapp\node_modules\@react-native-community\cli\build\tools\config\readConfigFromDisk.js',
    'D:\React\LCapp\LCapp\node_modules\@react-native-community\cli\build\tools\config\index.js', 'D:\React\LCapp\LCapp\node_modules\@react-native-community\cli\build\commands\install\install.js', 'D:\React\LCapp\LCapp\node_modules\@react-native-community\cli\build\commands\index.js', 'D:\React\LCapp\LCapp\node_modules\@react-native-community\cli\build\index.js', 'D:\React\LCapp\LCapp\node_modules\@react-native-community\cli\build\bin.js' ] }

1 Answer 1

0

You can try to use

yarn install

1
  • I tried it but the situation is still the same Commented May 6, 2021 at 13:26

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.