You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

parse-uri

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

parse-uri

Lightweight module for parsing an URI

2.0.1
Source
npmnpm
Version published
Weekly downloads
76K
7.06%
Maintainers
1
Weekly downloads
 
Created
Source

parse-uri

Last version Coverage Status NPM Status

Lightweight module for parsing an URI Based in Steven Levithan method.

Install

$ npm install parse-uri --save

Usage

const parseUri = require('parse-uri')

parseUri('myURL')

API

parseURI(str, [options])

options

strictMode

Type: boolean Default: false

Determinate if use loose or strict mode.

Loose mode deviates slightly from the official generic URI spec (RFC 3986)

Benchmark

Compared vs parseuri:

============================================================
simple          | parse-uri is 3302.0% faster
basic           | parse-uri is 1370.8% faster
complex         | parse-uri is 967.7% faster
mailto          | parse-uri is 1493.3% faster
tel             | parse-uri is 3296.8% faster
ftp             | parse-uri is 1641.9% faster
file            | parse-uri is 3305.7% faster
data            | parse-uri is 3030.4% faster
javascript      | parse-uri is 2992.0% faster
custom          | parse-uri is 1196.0% faster
longUrl         | parse-uri is 547.1% faster
unicodeUrl      | parse-uri is 1005.6% faster
============================================================

🏆 Overall Winner: parse-uri (2058.1% faster on average)

See more numbers at benchmark.

  • is-uri – Determinate if a string is a valid URI.

License

MIT © Kiko Beats

Keywords

URI

FAQs

Package last updated on 28 Jun 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