You're Invited:Meet the Socket Team at RSAC and BSidesSF 2026, March 23–26.RSVP
Socket
Book a DemoSign in
Socket

@types/validator

Package Overview
Dependencies
Maintainers
1
Versions
94
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/validator - npm Package Compare versions

Comparing version
13.15.8
to
13.15.9
+1
-0
validator/es/lib/isIP.d.ts
import validator from "../../";
export type IPVersion = validator.IPVersion;
export type IsIPOptions = validator.IsIPOptions;
export default validator.isIP;
import validator from "../../";
export type IsLatLongOptions = validator.IsLatLongOptions;
export default validator.isLatLong;
+18
-10

@@ -717,8 +717,15 @@ import * as _isBoolean from "./lib/isBoolean";

export interface IsIPOptions {
/**
* Defines which IP version to compare to.
*/
version?: IPVersion | undefined;
}
/**
* Check if the string is an IP (version 4 or 6).
*
* @param [version] - IP Version
* @param [version] - Defines which IP version to compare to.
*/
export function isIP(str: string, version?: IPVersion): boolean;
export function isIP(str: string, versionOrOptions?: IPVersion | IsIPOptions): boolean;

@@ -853,2 +860,9 @@ /**

export interface IsLatLongOptions {
/**
* Pass `checkDMS` as true to validate DMS(degrees, minutes, and seconds) latitude-longitude format.
* @default false
*/
checkDMS?: boolean | undefined;
}
/**

@@ -859,3 +873,3 @@ * Check if the string is a valid latitude-longitude coordinate in the format:

*/
export function isLatLong(str: string): boolean;
export function isLatLong(str: string, options?: IsLatLongOptions): boolean;

@@ -1511,9 +1525,3 @@ export interface IsLengthOptions {

*/
export function matches(str: string, pattern: RegExp): boolean;
/**
* Check if string matches the pattern.
*
* @param pattern - `'foo'`
* @param [modifiers] - `'i'`
*/
export function matches(str: string, pattern: RegExp | string): boolean;
export function matches(str: string, pattern: string, modifiers?: string): boolean;

@@ -1520,0 +1528,0 @@

import validator from "../";
export type IPVersion = validator.IPVersion;
export type IsIPOptions = validator.IsIPOptions;
export default validator.isIP;
import validator from "../";
export type IsLatLongOptions = validator.IsLatLongOptions;
export default validator.isLatLong;
{
"name": "@types/validator",
"version": "13.15.8",
"version": "13.15.9",
"description": "TypeScript definitions for validator",

@@ -84,4 +84,4 @@ "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/validator",

"peerDependencies": {},
"typesPublisherContentHash": "d659993453af71a9bad600583856a671fb8d2805050b080c0f29e60867f50993",
"typesPublisherContentHash": "b4eb26b65b7f92dc2a767ffaecabbc1296c799a33fad4ee317173b596f04829c",
"typeScriptVersion": "5.2"
}

@@ -11,3 +11,3 @@ # Installation

### Additional Details
* Last updated: Wed, 12 Nov 2025 18:39:33 GMT
* Last updated: Fri, 14 Nov 2025 18:02:08 GMT
* Dependencies: none

@@ -14,0 +14,0 @@