In my NX project, I have a capacitor Angular 14 application, when using cap:sync, I get the following error which stomps me.
> nx run caregiver:sync:ios --verbose=true
> NX Cannot find module 'nx/src/utils/app-root'
Require stack:
- /Users/yannickdesjardins/Documents/GitHub/nx-c4g/nx-c4g/node_modules/@nxtend/capacitor/node_modules/@nrwl/devkit/index.js
- /Users/yannickdesjardins/Documents/GitHub/nx-c4g/nx-c4g/node_modules/@nxtend/capacitor/src/executors/cap/executor.js
- /Users/yannickdesjardins/Documents/GitHub/nx-c4g/nx-c4g/node_modules/nx/src/config/workspaces.js
- /Users/yannickdesjardins/Documents/GitHub/nx-c4g/nx-c4g/node_modules/nx/src/command-line/run.js
- /Users/yannickdesjardins/Documents/GitHub/nx-c4g/nx-c4g/node_modules/nx/bin/run-executor.js
Error: Cannot find module 'nx/src/utils/app-root'
Require stack:
- /Users/yannickdesjardins/Documents/GitHub/nx-c4g/nx-c4g/node_modules/@nxtend/capacitor/node_modules/@nrwl/devkit/index.js
- /Users/yannickdesjardins/Documents/GitHub/nx-c4g/nx-c4g/node_modules/@nxtend/capacitor/src/executors/cap/executor.js
- /Users/yannickdesjardins/Documents/GitHub/nx-c4g/nx-c4g/node_modules/nx/src/config/workspaces.js
- /Users/yannickdesjardins/Documents/GitHub/nx-c4g/nx-c4g/node_modules/nx/src/command-line/run.js
- /Users/yannickdesjardins/Documents/GitHub/nx-c4g/nx-c4g/node_modules/nx/bin/run-executor.js
at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
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/yannickdesjardins/Documents/GitHub/nx-c4g/nx-c4g/node_modules/@nxtend/capacitor/node_modules/@nrwl/devkit/index.js:182:18)
at Module._compile (node:internal/modules/cjs/loader:1105:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1159:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at Module.require (node:internal/modules/cjs/loader:1005:19)
My nx report is the following: I use node 16, nx 14 and capacitor 13. I have research on the subject but can't seem to find the right answer.