Question: when I running my react-native project it gives following error:

> 
> Failed to compile.
> 
> 
> Module not found: Can't resolve 'uuid/v4' in 'F:\App 2nd\chat2\SecreteChat\node\_modules\expo-constants\build'
> 
> 
> 

How I solve this?

Answer: 
You have to update the node\_modules/expo-constants/exponentConstants.web.js

-- side note I was always run the expo web so I don't know if there is a Expoconstants.Android... or expoConstants.ios... that you will have to update as well. I also have been using yarn add \_\_\_\_ for most of my dependencies so if you were doing something different let us know. the error line above the error should tell you where it is originating from mine says its here:

```
Y:/Serviced/inService/node_modules/expo-constants/build/ExponentConstants.web.js

```

navigate to that file, and look around line number 3 in node\_modules/expo-constants/exponentConstants.web.js

```
import uuidv4 from 'uuid/v4

```

and change it to:

```
import {v4 as uuidv4} from 'uuid';

```

This error happens because of the file structure in node\_modules/uuid, if you look there is no longer a uuidv4 to import and instead they export a v4. You could change all the places where the developers wrote uuidv4 to v4 but using the { this **as** that } syntax you don't have to rewrite a bunch of code.
This worked for me

```
import * as uuid from 'uuid'

uuid.v4()

```