Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/david-vandensteen/net-keyboard
https://github.com/david-vandensteen/net-keyboard
Last synced: 4 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/david-vandensteen/net-keyboard
- Owner: David-Vandensteen
- License: mit
- Created: 2023-10-24T15:00:39.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-01-14T09:35:47.000Z (10 months ago)
- Last Synced: 2024-01-15T03:27:23.963Z (10 months ago)
- Language: JavaScript
- Size: 235 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# net-keyboard
## Install
```cmd
npm i [email protected]:David-Vandensteen/net-keyboard.git#release/2.0.2
```## Examples
### Server
```javascript
import { NetKeyboardServer } from 'net-keyboard';const { log } = console;
new NetKeyboardServer({ port: 8080 })
.on('data', (message) => {
log('data', message);
})
.serve();
```### Client
```javascript
import { NetKeyboardClient } from 'net-keyboard';new NetKeyboardClient('127.0.0.1', 8080)
.connect();
```### Local mode
```javascript
import { NetKeyboardServer } from 'net-keyboard';const { log } = console;
new NetKeyboardServer()
.on('data', (message) => {
log('data', message);
})
.serve();
```