# chartjs-adapter-dayjs-4

> ## Overview

Latest version **1.0.4** (published 2022-11-19) · MIT license · 0 weekly downloads

## Install

```sh
npm install chartjs-adapter-dayjs-4
pnpm add chartjs-adapter-dayjs-4
yarn add chartjs-adapter-dayjs-4
bun add chartjs-adapter-dayjs-4
```

## 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.0.4 |
| Published | 2022-11-19 |
| First published | 2022-11-19 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=10 |
| Dependencies | 0 |
| Unpacked size | 25.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 19 |
| Author | bolstycjw |
| Maintainers | bolstycjw |

## Links

- npm: https://www.npmjs.com/package/chartjs-adapter-dayjs-4
- Repository: https://github.com/bolstycjw/chartjs-adapter-dayjs-4
- Homepage: https://github.com/bolstycjw/chartjs-adapter-dayjs-4.git#readme
- Issues: https://github.com/bolstycjw/chartjs-adapter-dayjs-4.git/issues
- npm.io page: https://npm.io/package/chartjs-adapter-dayjs-4

## Recent versions

- 1.0.4 (latest) — 2022-11-19
- 1.0.3 — 2022-11-19
- 1.0.2 — 2022-11-19
- 1.0.1 — 2022-11-19
- 1.0.0 — 2022-11-19
- 1.2.3 — 2022-11-19

## README

# chartjs-adapter-dayjs-4

## Overview

This adapter allows the use of day.js with Chart.js time scale.

Requires Chart.js **4.0.1** or later and dayjs **1.9.7** or later.

**NOTE:** This adapter was designed for Chart.js v4 (which requires a separate date adapter for time scales to work properly), using this adapter in any version prior to 4 will override the default date-adapter

## Installation

### npm

```bash
npm install dayjs chartjs-adapter-dayjs-4 --save
```

```javascript
import Chart from 'chart.js';
import 'chartjs-adapter-dayjs-4/dist/chartjs-adapter-dayjs-4.esm';
```

## Configuration

### v4 [Chart.js documention](https://www.chartjs.org/docs/latest)

Read the Chart.js documention [v4](https://www.chartjs.org/docs/latest) for possible date/time related options. For example, the time scale `time.*` options [v4](https://www.chartjs.org/docs/latest/axes/cartesian/time.html#configuration-options) can be overridden using the [Day.js formats](https://day.js.org/docs/en/display/format).

## Development

You first need to install node dependencies (requires [Node.js](https://nodejs.org/)):

**_NPM_**

```bash
> npm install
```

**_Yarn_**

```bash
> yarn add
```

## License

`chartjs-adapter-dayjs-4` is available under the [MIT license](LICENSE.md).

## Credits

---

Moment Adapter source && README template

[Ben McCann](https://github.com/benmccann)

[Evert Timberg](https://github.com/etimberg)

[stockiNail](https://github.com/stockiNail)

---

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