This is an experimental PouchDB adapter for react-native-mmkv.
For example, one of the following:
- https://github.com/craftzdog/pouchdb-react-native
- https://github.com/stockulus/pouchdb-react-native
yarn add pouchdb-adapter-react-native-mmkv
import PouchDB from "@craftzdog/pouchdb-core-react-native";
// OR
import PouchDB from "pouchdb-react-native";
import { MMKV } from "react-native-mmkv";
import MMKVAdapterFactory from "pouchdb-adapter-react-native-mmkv";
const MMKVAdapter = MMKVAdapterFactory(MMKV);
const MMKVPouchDB = PouchDB.plugin(MMKVAdapter);
const myDB = new MMKVPouchDB("myDB", { adapter: "mmkv" });
- Clone repo and
cd
into it - Install dependencies and build lib
yarn && yarn build
- Run example
cd example && yarn && react-native run-ios