Skip to content

Instantly share code, notes, and snippets.

@leandrojo
Created March 10, 2020 18:45
Show Gist options
  • Save leandrojo/32883d6839095e47321ecebbb5486aa0 to your computer and use it in GitHub Desktop.
Save leandrojo/32883d6839095e47321ecebbb5486aa0 to your computer and use it in GitHub Desktop.
import { init, RematchRootState } from '@rematch/core';
import createPersistPlugin from '@rematch/persist';
import * as models from './models';
const persist = createPersistPlugin({
whitelist: [],
});
const store = init({
models,
plugins: [persist],
});
export type Dispatch = typeof store.dispatch;
export type State = RematchRootState<typeof models>
export default store;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment