JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • 0
  • Score
    100M100P100Q11104F
  • License MPL-2.0

A Custom Mongoose UUID SchemaType, to use for MongoDB Binary UUIDs

Package Exports

  • mongooseodm-uuid

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (mongooseodm-uuid) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Welcome to mongooseodm-uuid 👋

Version Documentation Maintenance License: ISC

A Custom Mongoose UUID SchemaType, to use for MongoDB Binary UUIDs (Subtype 0x03 and 0x04) (Subtype 0x03 follows the Java Driver implementation.)

Please note that inserting subtype 0x03 Binary UUIDs to the db is currently not supported

🏠 Homepage

Install

npm i mongooseodm-uuid

Run tests

npm run test

Usage

1) Register the SchemaType (insert somewhere like your index.js):

require('mongooseodm-uuid');

2) Use the SchemaType in a Mongoose Schema

const mongoose = require("mongoose");
const {MUUID} = require('mongooseodm-uuid');

const Schema = mongoose.Schema;

const HavocPunishmentSchema = new Schema({
    uuid: MUUID,
});

OR

const mongoose = require("mongoose");
const {MUUID} = require('mongooseodm-uuid');

const Schema = mongoose.Schema;

const HavocPunishmentSchema = new Schema({
    uuid: mongoose.Types.MUUID,
});

Author

👤 Max (https://github.com/gmax9803) (gmax@fourthfruit.com)

0xd3C43729AfE9751C29ff756531E105A76a8Ff9Cf

🤝 Contributing

Contributions, issues and feature requests are welcome!
Feel free to check issues page. You can also take a look at the contributing guide.

Show your support

Give a ⭐️ if this project helped you!

📝 License

Copyright © 2020 Max (https://github.com/gmax9803) (gmax@fourthfruit.com).
This project is ISC licensed.


This README was generated with ❤️ by readme-md-generator