1.1.2 • Published 3 years ago
parrot-share-localhost v1.1.2
README.md
Instantly share your localhost on internetcli
npx share-localhost
npx share-localhost -p YOUR_PORTif install as global npm module
share-localhost -p YOUR_PORT
local-out -p YOUR_PORT
lo -p YOUR_PORTinstall
yarn add share-localhostprovider
demo
import LocalOut, { EnumLocalOutEvent } from 'share-localhost';
import { console } from 'debug-color2'
let YOUR_PORT = 80;
let context = new LocalOut({
port: YOUR_PORT,
});
context.connect().tap(ret => {
console.log(`server online by`, 'hostname:', ret.hostname, 'port:', ret.port);
/**
* close connect
*/
context.close();
});