# clock.hypersource.club

> A HyperSource server that runs a hyperclock

Latest version **0.1.2** (published 2019-04-27) · MIT license · 0 weekly downloads

## Install

```sh
npm install clock.hypersource.club
pnpm add clock.hypersource.club
yarn add clock.hypersource.club
bun add clock.hypersource.club
```

Provides the command `clock.hypersource.club`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.2 |
| Published | 2019-04-27 |
| First published | 2019-04-27 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 6 |
| Unpacked size | 6.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 2 |
| Author | Joseph Werle |
| Maintainers | werle |
| Keywords | hypersource, club, hyperclock, server |

## Links

- npm: https://www.npmjs.com/package/clock.hypersource.club
- Repository: https://github.com/hypersource-club/clock.hypersource.club
- Homepage: https://github.com/hypersource-club/clock.hypersource.club#readme
- Issues: https://github.com/hypersource-club/clock.hypersource.club/issues
- npm.io page: https://npm.io/package/clock.hypersource.club

## Dependencies (6)

- [debug](https://npm.io/package/debug.md) ^4.1.1
- [minimist](https://npm.io/package/minimist.md) ^1.2.0
- [hypercore](https://npm.io/package/hypercore.md) ^6.26.0
- [hyperclock](https://npm.io/package/hyperclock.md) ^1.0.0
- [hypersource](https://npm.io/package/hypersource.md) ^0.1.6
- [random-access-memory](https://npm.io/package/random-access-memory.md) ^3.1.1

## Alternatives

- [jsforce](https://npm.io/package/jsforce.md) — 851.2K weekly downloads
- [react-native-qrcode-svg](https://npm.io/package/react-native-qrcode-svg.md) — 693.5K weekly downloads
- [@salesforce/plugin-data](https://npm.io/package/@salesforce/plugin-data.md) — 394.9K weekly downloads
- [@backstage/plugin-search-common](https://npm.io/package/@backstage/plugin-search-common.md) — 308.5K weekly downloads
- [@chain-registry/types](https://npm.io/package/@chain-registry/types.md) — 38.4K weekly downloads

## Recent versions

- 0.1.2 (latest) — 2019-04-27
- 0.1.1 — 2019-04-27
- 0.1.0 — 2019-04-27

## README

clock.hypersource.club
======================

A simple HyperSource clock server

## Installation

```js
$ npm install -g clock.hypersource.club
```

## Usage

```sh
$ clock.hypersource.club --port 3000 --host '127.0.0.1'
```

or with `npx`

```sh
$ npx clock.hypersource.club --port 3000 --host '127.0.0.1'
```

Create a new clock stream with
[hypersource-client](https://github.com/jwerle/hypersource-client).

```sh
$ hsurl ws://clock.hypersource.club --live --output ./clock
```

or programmatically

```js
const hyperclock = require('hyperclock')
const ram = require('random-access-memory')
const client = require('hypersource-client')(hyperclock(ram), 'wss://clock.hypersource.club')
client.connect((err, res) => {
  res.createReadStream(({ live: true }).on('data', console.log)
})
```

which outputs

```
...
{ time: 1556405496684,
  random:
   <Buffer 6a 84 3d b4 18 0c 21 0f 7e 21 ec 13 21 3a c1 40 58 a9 05 0c d5 00 9d 27 ce 31 33 77 8d d5 95 1d> }
{ time: 1556405497683,
  random:
   <Buffer a5 80 8b 84 77 f7 61 9b 13 72 e9 f7 33 52 1e 62 27 e3 a7 4b 22 42 09 e5 06 e1 42 74 87 47 fd 47> }
...
```

## API

### `server = require('clock.hypersource.club')()`

Create a [hypersource](https://github.com/jwerle/hypersource) server

#### Example

```js
const server = require('clock.hypersource.club')()
server.listen(3000)
server.on('request', (req) => {
  console.log('%s %s', req.method, req.url)
})
```

## License

MIT

---
_Source: https://npm.io/package/clock.hypersource.club · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
