0.2.2 • Published 1 month ago

node-mongoose-audit v0.2.2

Weekly downloads
-
License
ISC
Repository
github
Last release
1 month ago

Database Audit Package

This package provides functionality for auditing database changes in mongoose.

Installation

To install the package, run the following command:

npm install node-mongoose-audit

Setting up Database Connection

import { initConnection } from 'node-mongoose-audit'; 

Provide Database Uri

initConnection(uri);

Usage

To add after defining your schema: example:

import mongoose from 'mongoose';
import diffHistory from 'node-mongoose-audit';
 
const testSchema = new mongoose.Schema({
    someField: String,
    some: {
        deepField: String
    }
});
 
testSchema.plugin(diffHistory);
0.2.2

1 month ago

0.1.0

1 month ago

0.2.1

1 month ago

0.2.0

1 month ago

0.0.0

1 month ago