Introducing Socket Firewall: Free, Proactive Protection for Your Software Supply Chain.Learn More
Socket
Book a DemoInstallSign in
Socket

@wegolook/joi-objectid

Package Overview
Dependencies
Maintainers
12
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@wegolook/joi-objectid

Extends Joi with Joi.objectId()

latest
npmnpm
Version
6.2.1
Version published
Maintainers
12
Created
Source

@wegolook/joi-objectid

Joi extension to support BSON ObjectId

Usage

// import and assignment
const Joi = require('joi'); // use version ^9.0.0
const joiObjectId = require('@wegolook/joi-objectid');
const myJoi = Joi.extend(joiObjectId);

// ...then
const result = myJoi.objectId().validate(myObjectId);
// result.value, result.errors, etc...

// ...or
myJoi.objectId().validate(myObjectId, (err, value) => { /*...*/ });

CI Status

Codeship Status for wegolook/joi-objectid

Keywords

hapi

FAQs

Package last updated on 24 Apr 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts