# @bluewaitor/mongoose-plugin-timestamp

> mongoose simple timestamp plugin

Latest version **1.0.4** (published 2017-07-26) · MIT license · 0 weekly downloads

## Install

```sh
npm install @bluewaitor/mongoose-plugin-timestamp
pnpm add @bluewaitor/mongoose-plugin-timestamp
yarn add @bluewaitor/mongoose-plugin-timestamp
bun add @bluewaitor/mongoose-plugin-timestamp
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.4 |
| Published | 2017-07-26 |
| First published | 2017-03-16 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | bluewaitor |
| Maintainers | bluewaitor |
| Keywords | mongoose, plugin, timestamp |

## Links

- npm: https://www.npmjs.com/package/@bluewaitor/mongoose-plugin-timestamp
- Repository: https://github.com/bluewaitor/mongoose-plugin-timestamp
- Homepage: https://github.com/bluewaitor/mongoose-plugin-timestamp#readme
- Issues: https://github.com/bluewaitor/mongoose-plugin-timestamp/issues
- npm.io page: https://npm.io/package/@bluewaitor/mongoose-plugin-timestamp

## Alternatives

- [angular-pipes](https://npm.io/package/angular-pipes.md) — 5.6K weekly downloads
- [@ng-web-apis/midi](https://npm.io/package/@ng-web-apis/midi.md) — 2.6K weekly downloads
- [happn-3](https://npm.io/package/happn-3.md) — 1.6K weekly downloads
- [@opensip-cli/lang-go](https://npm.io/package/@opensip-cli/lang-go.md) — 1.2K weekly downloads
- [mongoose-typescript](https://npm.io/package/mongoose-typescript.md) — 85 weekly downloads

## Recent versions

- 1.0.4 (latest) — 2017-07-26
- 1.0.3 — 2017-07-26
- 1.0.2 — 2017-07-25
- 1.0.1 — 2017-03-22
- 1.0.0 — 2017-03-16

## README

# mongoose-plugin-timestamps
mongoose plugin auto create timestamp and update timestamp.

# Usage

## install

`npm install @bluewaitor/mongoose-plugin-timestamp --save`

## use in global

```
    const mongoose = require('mongoose');
    const timestampPlugin = require('@bluewaitor/mongoose-plugin-timestamp');

    mongoose.plugin(timestampPlugin, {index: true});
```


### use in schema

```
    const someSchema = mongoose.Schema({});
    someSchema.plugin(timestampPlugin, {index: true});
```

### properties
this plugin will create two properties `created` and `updated` in models. custom properties not support yet.

---
_Source: https://npm.io/package/@bluewaitor/mongoose-plugin-timestamp · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
