feat(types): Add TypeScript typings for ssr (#673)
This commit is contained in:
committed by
Guillaume Chau
parent
b0861dd34e
commit
c4b6aa545c
Vendored
+21
@@ -0,0 +1,21 @@
|
||||
import {ApolloProvider} from "vue-apollo";
|
||||
|
||||
interface GetStatesOptions {
|
||||
exportNamespace?: string;
|
||||
}
|
||||
|
||||
interface ExportStatesOptions {
|
||||
globalName?: string;
|
||||
attachTo?: string;
|
||||
useUnsafeSerializer?: boolean;
|
||||
}
|
||||
|
||||
interface ApolloSsr {
|
||||
serializeStates(provider: ApolloProvider, options?: GetStatesOptions): string
|
||||
getStates(provider: ApolloProvider, options?: GetStatesOptions): {[key: string]: {}}
|
||||
exportStates(provider: ApolloProvider, options: ExportStatesOptions): string
|
||||
}
|
||||
|
||||
declare const ssr: ApolloSsr
|
||||
|
||||
export default ssr;
|
||||
Reference in New Issue
Block a user