- React.useEffect(async () => {
- const stored = await localforage.getItem('alttpBaseRom');
- if (stored) {
- const crc = CRC32.buf(new Uint8Array(stored));
- if (crc == 0x3322EFFC) {
- setRom(stored);
+ React.useEffect(() => {
+ (async () => {
+ const stored = await localforage.getItem('alttpBaseRom');
+ if (stored) {
+ const crc = CRC32.buf(new Uint8Array(stored));
+ if (crc == 0x3322EFFC) {
+ setRom(stored);
+ }