js-api-loader
js-api-loader copied to clipboard
Question getting type returned from Loader
I'm using a state library that will hold the dynamically loaded google api to use across many components.
// I have something like this
export const googleVar = makeVar<any>(null);
// but I want something like this
export const googleVar = makeVar<Google | null>(null);
I've followed the steps and installed DefinitelyTyped's types. However I don't know the best way to import the global return type for loader.load.