# mk8dx

> This library has mk8dx's track data and lounge api wrapper.

Latest version **1.5.11** (published 2023-08-20) · MIT license · 0 weekly downloads

## Install

```sh
npm install mk8dx
pnpm add mk8dx
yarn add mk8dx
bun add mk8dx
```

## Health

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

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.5.11 |
| Published | 2023-08-20 |
| First published | 2023-04-18 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 4 |
| Unpacked size | 468.4 KB |
| Known vulnerabilities | 0 (+16 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 2 |
| Maintainers | sheat |

## Links

- npm: https://www.npmjs.com/package/mk8dx
- Repository: https://github.com/sheat-git/mk8dx.js
- Homepage: https://github.com/sheat-git/mk8dx.js#readme
- Issues: https://github.com/sheat-git/mk8dx.js/issues
- npm.io page: https://npm.io/package/mk8dx

## Dependencies (4)

- [undici](https://npm.io/package/undici.md) ^5.21.0
- [chart.js](https://npm.io/package/chart.js.md) *
- [@deno/shim-deno](https://npm.io/package/@deno/shim-deno.md) ~0.15.0
- [@napi-rs/canvas](https://npm.io/package/@napi-rs/canvas.md) *

## Recent versions

- 1.5.11 (latest) — 2023-08-20
- 1.5.10 — 2023-08-08
- 1.5.9 — 2023-08-01
- 1.5.8 — 2023-07-17
- 1.5.7 — 2023-05-24
- 1.5.6 — 2023-05-24
- 1.5.5 — 2023-05-24
- 1.5.4 — 2023-05-24
- 1.5.3 — 2023-05-24
- 1.5.2 — 2023-05-24
- 1.5.1 — 2023-05-23
- 1.4.0 — 2023-05-19
- 1.3.0 — 2023-05-19
- 1.2.0 — 2023-05-19
- 1.1.1 — 2023-05-17
- … 2 more at https://npm.io/package/mk8dx/versions

## README

# mk8dx.js
This library has mk8dx's track data and lounge api wrapper.

## Track Data

```TypeScript
import { searchTrack } from 'mk8dx'

console.log(searchTrack('tokyo').abbr)
// 'bTB'
```

## Lounge API Wrapper

```TypeScript
import { Lounge } from 'mk8dx'

Lounge.getPlayer({ name: 'sheat' })
    .then(player => {
        console.log(player.switchFc)
        // '6986-4603-1885'
    })
```

## Lounge Chart

```TypeScript
import { Chart } from 'chart.js'
import { createCanvas } from 'canvas'
import * as fs from 'fs'
import { Lounge } from 'mk8dx'

const playerDetails = await Lounge.getPlayerDetails({ name: 'kusaan', season: 7 })
const canvas = createCanvas(1280, 720)
new Chart(canvas.getContext('2d'), Lounge.createStatsChartConfig({
    season: playerDetails.season,
    data: Lounge.createStatsChartData(playerDetails.mmrChanges)
}))
fs.writeFile('stats.png', canvas.toBuffer('image/png'))
```

![](stats.png)

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