Skip to content

Commit b62a4d3

Browse files
fix(integrations): Add localforage typing (#2856)
Co-authored-by: Rodolfo Carvalho <rodolfo.carvalho@sentry.io>
1 parent 1038bbe commit b62a4d3

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

packages/integrations/src/offline.ts

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import { Event, EventProcessor, Hub, Integration } from '@sentry/types';
22
import { getGlobalObject, logger, uuid4 } from '@sentry/utils';
3-
// @ts-ignore: Module '"localforage"' has no default export.
4-
import localforage from 'localforage';
3+
import * as localForage from 'localforage';
54

65
/**
76
* cache offline errors and send when connected
@@ -43,7 +42,7 @@ export class Offline implements Integration {
4342
public constructor(options: { maxStoredEvents?: number } = {}) {
4443
this.global = getGlobalObject<Window>();
4544
this.maxStoredEvents = options.maxStoredEvents || 30; // set a reasonable default
46-
this.offlineEventStore = localforage.createInstance({
45+
this.offlineEventStore = localForage.createInstance({
4746
name: 'sentry/offlineEventStore',
4847
});
4948

0 commit comments

Comments
 (0)