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 May 9, 2024 via pnpm

relateurl 0.2.7

Minify URLs by converting them from absolute to relative.
Package summary
Share
0
issues
1
license
1
MIT
Package created
28 Mar 2014
Version published
14 Jul 2016
Maintainers
1
Total deps
1
Direct deps
0
License
MIT

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:
relateurl@0.2.7
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

0
All Dependencies CSV
β“˜ This is a list of relateurl 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities

Visualizations

Frequently Asked Questions

What does relateurl do?

RelateUrl is a powerful JavaScript utility that minifies URLs, converting them from absolute URLs to relative URLs. It performs string parsing and does not require directory browsing. It's highly optimized, delivering impressive speed and lightness, all without requiring any external dependencies.

How do you use relateurl?

To start using RelateUrl, you need to have Node.js (version 0.10 or later) installed on your machine. You can then install the package by typing the following command in your terminal:

npm install relateurl --save-dev

RelateUrl can be used either as a function for single-use or as a class for multiple conversions.

Here's an example of single-use:

var RelateUrl = require("relateurl");

var result = RelateUrl.relate(from, to, options);

And here's how you can create reusable instances:

var RelateUrl = require("relateurl");

var instance = new RelateUrl(from, options);

var result1 = instance.relate(to1);
var result2 = instance.relate(to2, customOptions);
var result3 = instance.relate(to3);

In these examples, from and to are the URLs you want to convert, and options is an optional object where you can specify various settings, such as whether to ignore 'www', or whether to remove authentication info from the URL.

Where are the relateurl docs?

For comprehensive information about RelateUrl and its uses, refer to its GitHub page. The README file on this page provides detailed instructions on how to install and utilize the tool, its features and options, and also gives code examples. Additional updates about the tool's release history and roadmap can also be found on this page.