Package Exports
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (purrl) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
purrl
Installation
Install purrl
as a dev dependency of your project
pnpm add -D purrl
Usage
Run purrl
in your terminal or add it into your package.json
scripts.
[!NOTE] You need to run
purrl
withsudo
since it needs to modify the/etc/hosts
file and listen to ports80
and443
(in case of https).
From terminal
sudo pnpm purrl localhost:3000 example.local
From package.json
{
"scripts": {
"start-proxy": "sudo purrl localhost:3000 example.local"
}
}
Examples
Expose localhost to example.local
purrl localhost:3000 example.local
Now browse http://example.local in your browser to see the result.
Expose localhost to example.local with https
purrl localhost:3000 example.local --ssl
Now browse https://example.local in your browser to see the result.
Specification
USAGE
purrl localhost:3000 example.local
purrl localhost:3000 example.local --ssl # expose with https
purrl --help
purrl --version
Expose your localhost to a custom local domain
FLAGS
[--ssl] If passed the destination will be exposed over HTTPS [default = false]
-h --help Print help information and exit
-v --version Print version information and exit
ARGUMENTS
arg1 Origin path
arg2 Destination path