lokal-js
v0.0.11
Published
Library for interacting with Lokal.so Client REST API
Downloads
68
Readme
Lokal JS
Library for interacting with Lokal Client REST API
npm i lokal-js
import { Lokal } from 'lokal-js';
async function main() {
const lokal = new Lokal();
const tunnel = await lokal
.newTunnel()
.setLocalAddress('localhost:3000')
.setTunnelType('HTTP')
// .setPublicAddress('myapp.k.lokal-so.site')
.setLANAddress('my-app.local')
.showStartupBanner()
.ignoreDuplicate()
.create();
const lanAddress = await tunnel.getLANAddress();
console.log('LAN Address:', lanAddress);
}
main().catch(console.error);