Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report
Generated on Mar 13, 2024 via pnpm

uri-js 4.4.1

An RFC 3986/3987 compliant, scheme extendable URI/IRI parsing/validating/resolving library for JavaScript.
Package summary
Share
0
issues
2
licenses
1
MIT
1
BSD-2-Clause
Package created
13 Mar 2012
Version published
10 Jan 2021
Maintainers
1
Total deps
2
Direct deps
1
License
BSD-2-Clause

Issues

0
This package has no issues

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
punycode@2.3.1

BSD 2-Clause "Simplified" License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
place-warranty
Cannot
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
uri-js@4.4.1
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

1
All Dependencies CSV
β“˜ This is a list of uri-js 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities
punycode2.3.17.42 kBMIT
prod

Visualizations

Frequently Asked Questions

What does uri-js do?

URI.js is a JavaScript library that provides parsing, validating and resolving functionality for URIs (Uniform Resource Identifiers) and IRIs (International Resource Identifiers). Fully compliant with multiple RFC (Request for Comments) standards, the library is extendable, allowing custom scheme-dependent processing rules. It also has features for comparing and normalizing URIs, supporting both IPv4 and IPv6 and is designed with versatility for usage in any JavaScript environment, including browsers and Node.js.

How do you use uri-js?

URI.js is available as an npm package and can be installed via npm or yarn. Here's an example of the installation command:

    npm install uri-js
    # OR
    yarn add uri-js

Then, in your JavaScript file, you can require it as follows:

    const URI = require("uri-js");

Alternatively, if you're using ES6+ syntax (ESNEXT) or TypeScript, you can import it this way:

    import * as URI from "uri-js";

Using URI.js involves invoking its methods such as parse(), serialize(), normalize(), resolve(), and others on your URIs. Here are some usage examples:

    //Parse a URI
    let parsed = URI.parse("uri://user:pass@example.com:123/one/two.three?q1=a1&q2=a2#body");

    //Serialize a URI
    let serialized = URI.serialize({scheme : "http", host : "example.com", fragment : "footer"});

    //Normalize a URI
    let normalized = URI.normalize("HTTP://ABC.com:80/%7Esmith/home.html");

    //Resolve a URI
    let resolved = URI.resolve("uri://a/b/c/d?q", "../../g");

Where are the uri-js docs?

The detailed documentation and API references for URI.js are located directly in the README of the GitHub repository. The documentation provides a thorough explanation of each method available in the library and demonstrates how to use the library with specific use case examples. The GitHub repository can be accessed through the link: git+ssh://git@github.com/garycourt/uri-js.git.