feat: unique device id
This commit is contained in:
@ -1,7 +1,14 @@
|
||||
import type { FC } from "react";
|
||||
import { useEffect, useState, type FC } from "react";
|
||||
import { getDeviceId } from "./util/deviceId";
|
||||
|
||||
const App: FC = () => {
|
||||
return <div>Hello</div>;
|
||||
const [deviceId, setDeviceId] = useState("");
|
||||
|
||||
useEffect(() => {
|
||||
getDeviceId().then((id) => setDeviceId(id));
|
||||
}, []);
|
||||
|
||||
return <div>{deviceId}</div>;
|
||||
};
|
||||
|
||||
export default App;
|
||||
|
Reference in New Issue
Block a user