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: 
Here are the steps i followed to resolve it:

* install uuid (I assume you've done this already).

`npm install uuid`
* Then import uuidv4 from uuid library

`const { v4: uuidv4 } = require('uuid');`
* You can then go ahead to use it. eg:

```
const expenseList = [
   { id: uuidv4(), expenseItem: "rent", amount: 1000 },
   { id: uuidv4(), expenseItem: "car note", amount: 2000 },
   { id: uuidv4(), expenseItem: "mortgage", amount: 3000 },
]; 

```
Install the package using:

```
npm install uuid

```