open-index/open-npm huggingface dataset:
npm package: @hrtk92/mcwsjs
Description: ![npm](https://img.shields.io/npm/v/@hrtk92/mcwsjs) ![npm](https://img.shields.io/npm/dt/%40hrtk92%2Fmcwsjs) [![GitHub Release](https://github.com/HRTK92/mcws.js/actions/workflows/release.yml/badge.svg)](https://github.com/HRTK92/mcws.js/actions/workflows
Author: はらたく
Latest version: 1.1.5

# mcws.js

![npm](https://img.shields.io/npm/v/@hrtk92/mcwsjs)
![npm](https://img.shields.io/npm/dt/%40hrtk92%2Fmcwsjs)
[![GitHub Release](https://github.com/HRTK92/mcws.js/actions/workflows/release.yml/badge.svg)](https://github.com/HRTK92/mcws.js/actions/workflows/release.yml)

mcws.js is a library that makes it **easy** to start a Minecraft WebSocket server.

## Install

```sh
$ yarn add @hrtk92/mcwsjs
```

## Usage

Here is a detailed explanation of how to use this library:

- Step 1: Import the library in your project
- Step 2: Create an instance of the `mcws` class, passing in the host and port as arguments
- Step 3: Call the `createServer()` method to start the server
- Step 4: Register event listeners using the `on()` method to receive events from the Minecraft server
- Step 5: Use the `sendCommand()` method to send commands to the Minecraft server

## Example

```js
import { mcws, Events } from '@hrtk92/mcwsjs'

const mcserver = new mcws('localhost', 8000)

mcserver.onReady((host, port) => {
    console.log('Server started')
    console.log(`/wsserver ${host}:${port}`)
})

mcserver.onConnection(() => {
    console.log('Connected to Minecraft')
    mcserver.sendCommand('say Connected') // send command
    mcserver.subscribe(Events.PlayerMessage) // register events to receive
})

mcserver.on(Events.PlayerMessage, (data) => {
    console.log(`${data.body.message} by ${data.body.sender}`)
})

mcserver.onDisconnect(() => {
    console.log('Disconnected')
})

mcserver.createServer() // start the server

```

## Events

### onReady

Called when the server is started

### onConnect

Called when connected to Minecraft

### onDisconnect

Called when the connection is disconnected

### on(event, callback)

Called when the [event](https://github.com/HRTK92/mcwsjs/blob/main/src/events.ts) specified by event occurs

> **Note**  
> I used [this gist](https://gist.github.com/jocopa3/5f718f4198f1ea91a37e3a9da468675c#file-mcpe-w10-event-names) as a reference to create an event list.

## Command

```ts
mcserver.sendCommand('say hello')
```

You can send commands.

> **Warning**  
> There is no need to add a `/` at the beginning.
npm package: @hrueger/changelogjs
Description: A small customizable changelog generator
Author: H. Rüger
Latest version: 1.0.1

# ChangelogJS

[![npm](https://img.shields.io/npm/v/@hrueger/changelogjs)](https://npmjs.com/package/changelogjs)
[![Greenkeeper badge](https://badges.greenkeeper.io/hrueger/changelogjs.svg)](https://greenkeeper.io/)
[![License](https://img.shields.io/badge/License-MIT-blue)](./LICENSE.md)
[![GitHub last commit](https://img.shields.io/github/last-commit/hrueger/changelogjs?color=brightgreen)](https://github.com/hrueger/changelogjs/commits)
[![Maintenance](https://img.shields.io/maintenance/yes/2020)](https://github.com/hrueger/changelogjs/commits)

This is a small customizable changelog generator.

It generates the changelog based on **commit messages**, not on release notes.

The following modes are avalible:
| HTML | MD | JSON |
| ---- | -- | ---- |
| `html-gh` | `md` | `json` |
| ![Example HTML output](./example_html_output.png) | ![Example Markdown output](./example_md_output.png) | ![Example JSON output](./example_json_output.png) |

## Installation
Type `npm install @hrueger/changelogjs --global` into your terminal.

## Usage
`changelogjs` without any options. If a `changelogjs.json` file is found in the current folder or above, this is used as the configuration instead of the default values (see below).

## Configuration
Create a `changelogjs.json` file ans specify the options below:

| Option | Description | Default |
| ------ | ----------- | ------- |
| `title` | The title of the Markdown and HTML page. | `Changelog for your App` |
| `logoUrl` | The url of a Logo image to be displayed at the top of the HTML page. | Some placeholder image. |
| `logoAlt` | The alternative text for the logo. | `Logo` |
| `sort` | A `boolean` value whether the commit messages of one day should be sorted after their type or not. | `true` |
| `ignoreAuthors` | An `array` of `string` values with authors which should be ignored. | `["greenkeeper[bot]"]` |
| `headerLinks` | An array of `{url: "someUrl", text: "text to be displayed", active: false|true}` objects to be displayed as links in the header of the HTML page. | `[{url: "/", text: "Docs"}, {url: "#", text: "Changelog", active: true}]` |
| `footerLinks` | An array of `{url: "someUrl", text: "text to be displayed"}` objects to be displayed as links in the footer of the HTML page. | `[{url: "#", text: "View on GitHub"}, {url: "https://github.com/hrueger/changelogjs", text: "Generated by ChangelogJS"}]` |
| `modes` | An array of `{mode: "md"|"json"|"html-gh", file: "someFileName.ext"}` objects defining which output files with which modes should be generated. See above for the avalible modes. | `[{mode: "md", file: "CHANGELOG.md"}, {mode: "json", file: "CHANGELOG.json"}, {mode: "html-gh", file: "CHANGELOG.html"}]` |

## Contribute
Feel free to report any issues on GitHub or add new modes / features and create a pull request!

## License
MIT