文件名称:joi-extension-semver:Joi验证库的Semver扩展
文件大小:49KB
文件格式:ZIP
更新时间:2024-04-21 02:54:21
JavaScript
joi-extension-semver 验证库的Semver扩展 用法 const { semver , semverRange } = require ( 'joi-extension-semver' ) const Joi = require ( 'joi' ) . extend ( semver ) . extend ( semverRange ) Joi . attempt ( '1.2.3' , Joi . semver ( ) . valid ( ) ) // '1.2.3' Joi . attempt ( '>=1.2.3' , Joi . semverRange ( ) . valid ( ) ) // '>=1.2.3' Joi . attempt ( '1.2.3' , Joi . semver ( ) . gte ( '1.2.3' ) ) //
【文件预览】:
joi-extension-semver-master
----.eslintrc.yml(404B)
----.gitignore(64B)
----README.MD(3KB)
----package.json(1KB)
----package-lock.json(167KB)
----LICENSE(1KB)
----index.js(4KB)
----CHANGELOG.md(1KB)
----types()
--------tslint.json(123B)
--------tests.ts(482B)
--------tsconfig.json(213B)
--------index.d.ts(821B)
----.github()
--------workflows()
----index.spec.js(6KB)