@fission-codes/homestar
v2.4.0
Published
Homestar Client.
Downloads
25
Readme
Homestar
Installation
pnpm install @fission-codes/homestar
Usage
import { Homestar } from '@fission-codes/homestar'
import { WebsocketTransport } from '@fission-codes/homestar/transports/ws.js'
// if you need isomorphic support
import { WebSocket } from 'unws'
const hs = new Homestar({
transport: new WebsocketTransport('ws://localhost:8060', {
ws: WebSocket,
}),
})
hs.on('error', (error) => {
console.error(error)
})
const { error, result } = await hs.metrics()
if (error) {
console.error(error)
}
hs.close()
Docs
Check https://fission-codes.github.io/stack
Contributing
Read contributing guidelines here.
License
This project is licensed under either of
- Apache License, Version 2.0, (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option.
Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.