ark.db
ark.db copied to clipboard
Your treeshaking is not working?
I'm building this simple file, using vite (practically rollup)
import { LocalStorage } from 'ark.db';
const datastore = new LocalStorage();
function read(dataPath) {
return datastore.get(dataPath);
}
function write(dataPath, payload) {
return datastore.set(
dataPath,
(payload?.(datastore.get(dataPath)) || payload)
);
}
export {
read,
write
};
Now, my production build is 972.25kb!
It seems the whole Mongoose is in the ark.db's production build.
How are you included the ark.db in your project?