diff --git a/src/features.ts b/src/features.ts index 564af09..284e8c2 100644 --- a/src/features.ts +++ b/src/features.ts @@ -7,7 +7,7 @@ import * as firestore from './providers/firestore'; import * as pubsub from './providers/pubsub'; import * as storage from './providers/storage'; -export interface FeaturesList { +export interface LazyFeatures { mockConfig: typeof mockConfig; wrap: typeof wrap; makeChange: typeof makeChange; @@ -20,7 +20,7 @@ export interface FeaturesList { storage: typeof storage; } -export const features: FeaturesList = { +export const features: LazyFeatures = { mockConfig, wrap, makeChange, @@ -32,3 +32,7 @@ export const features: FeaturesList = { pubsub, storage, }; + +export interface FeaturesList extends LazyFeatures { + cleanup; +} diff --git a/src/index.ts b/src/index.ts index ebbfcb4..2b69ce3 100644 --- a/src/index.ts +++ b/src/index.ts @@ -35,5 +35,5 @@ export = (firebaseConfig?: AppOptions) => { features = merge({}, features, { cleanup: () => test.cleanup, }); - return features; + return features as FeaturesList; };