I have the following libraries installed on my M1 Macbook running Ventura 13.3.1:
$ nvm -v
0.39.3
$ node -v
v18.16.0
$ npm -v
9.6.4
$ npx expo -v
0.7.0
I generated a new expo project using the command:
npx create-expo-app my-app --template
I choose the blank Typescript template. It generated an app and then I cd into the app directory. When I run npx run web
, first it asks for me to install some dependencies, so then I do:
npx expo install react-native-web@~0.18.10 [email protected] @expo/webpack-config@^18.0.1
Now when I try to run npx run web
, I get the following error:
/Users/paul/.npm/_npx/755986f37193a6d8/node_modules/run/run.js:127
if (minimatch(file, pattern)) {
^
TypeError: minimatch is not a function
How get I fix this error and get the expo server to start?
2
Answers
The minimatch is used internally by npm, and this error occurs due to a problem installing the dependencies.
To fix it, just delete the
node_modules
folder and runnpm install
.Now everything should work perfectly!
I was getting this when trying to run an Astro project:
The problem was that I was actually supposed to be running
npm run
: