Generating id while creating a new device

This commit is contained in:
Manoj Vivek 2023-03-30 10:59:02 +05:30
parent c9f0c58973
commit 8475f275a0

View file

@ -1,4 +1,5 @@
import { Device } from 'common/deviceList';
import { randomUUID } from 'crypto';
import { useEffect, useState } from 'react';
import Button from '../Button';
import Input from '../Input';
@ -93,6 +94,7 @@ const DeviceDetailsModal = ({
}
await onAddDevice(
{
id: randomUUID(),
name,
width,
height,