Skip to content

Interface: UriOptions

Properties

PropertyTypeDescription
allowQuerySquareBrackets?booleanAllows unencoded square brackets inside the query string. This is NOT RFC 3986 compliant but query strings like abc[]=123&abc[]=456 are very common these days. Default false
allowRelative?booleanAllow relative URIs. Default false
domain?DomainOptionsValidate the domain component using the options specified in string.domain().
encodeUri?booleanEncode URI before validation. Default false
relativeOnly?booleanRestrict only relative URIs. Default false
scheme?string | RegExp | (string | RegExp)[]Specifies one or more acceptable Schemes, should only include the scheme name. Can be an Array or String (strings are automatically escaped for use in a Regular Expression).