# @cuties/date

> Cutie extension for work with Date object in JavaScript.

Latest version **1.1.2** (published 2019-05-10) · MIT license · 0 weekly downloads

## Install

```sh
npm install @cuties/date
pnpm add @cuties/date
yarn add @cuties/date
bun add @cuties/date
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.1.2 |
| Published | 2019-05-10 |
| First published | 2018-08-28 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 6 |
| Unpacked size | 40.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | guseyn |
| Maintainers | guseyn |
| Keywords | cutie, date |

## Links

- npm: https://www.npmjs.com/package/@cuties/date
- Repository: https://github.com/Guseyn/cutie-date
- Homepage: https://github.com/Guseyn/cutie-date#readme
- Issues: https://github.com/Guseyn/cutie-date/issues
- npm.io page: https://npm.io/package/@cuties/date

## Dependencies (6)

- [@cuties/is](https://npm.io/package/@cuties/is.md) ^1.1.2
- [@cuties/wall](https://npm.io/package/@cuties/wall.md) ^1.1.2
- [@cuties/cutie](https://npm.io/package/@cuties/cutie.md) ^1.7.5
- [test-executor](https://npm.io/package/test-executor.md) ^1.2.4
- [@cuties/assert](https://npm.io/package/@cuties/assert.md) ^1.2.2
- [@cuties/iterator](https://npm.io/package/@cuties/iterator.md) ^1.1.2

## Alternatives

- [@js-joda/timezone](https://npm.io/package/@js-joda/timezone.md) — 383.4K weekly downloads
- [chartjs-adapter-moment](https://npm.io/package/chartjs-adapter-moment.md) — 210.8K weekly downloads
- [strftime](https://npm.io/package/strftime.md) — 171.2K weekly downloads
- [vue-flatpickr-component](https://npm.io/package/vue-flatpickr-component.md) — 115.8K weekly downloads
- [timepicker](https://npm.io/package/timepicker.md) — 51.0K weekly downloads

## Recent versions

- 1.1.2 (latest) — 2019-05-10
- 1.1.1 — 2019-05-10
- 1.1.0 — 2019-02-21
- 1.0.10 — 2019-02-17
- 1.0.9 — 2019-02-17
- 1.0.8 — 2019-02-16
- 1.0.7 — 2018-09-22
- 1.0.6 — 2018-08-28

## README

# cutie-date

[![NPM Version](https://img.shields.io/npm/v/@cuties/date.svg)](https://npmjs.org/package/@cuties/date)
[![Build Status](https://travis-ci.org/Guseyn/cutie-date.svg?branch=master)](https://travis-ci.org/Guseyn/cutie-date)
[![codecov](https://codecov.io/gh/Guseyn/cutie-date/branch/master/graph/badge.svg)](https://codecov.io/gh/Guseyn/cutie-date)

[Cutie](https://github.com/Guseyn/cutie) extension for work with </b>Date</b> object in JavaScript. It's based on the [Async Tree Pattern](https://github.com/Guseyn/async-tree-patern/blob/master/Async_Tree_Patern.pdf).


## Examples

You can find examples of using this library in the [test directory](https://github.com/Guseyn/cutie-date/tree/master/test).

## Install

`npm install @cuties/date`

## Run test

`npm test`

## Run build

`npm run build`

## Usage

```js
const {
  // Needed async objects here from the table below
} = require('@cuties/date');
```
For more information about parameters in the async objects visit [MDN docs for Date global object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date).

| Async Object | Async/sync call | Parameters(default value/description) | Representation result |
| ------------- | ----------------| ---------- | --------------------- |
| `Date` | `new Date(...params)` | `...params` | `date` |
| `DateAsString` | `date.toString` | `date` | `string` |
| `DateJSON` | `date.toJSON` | `date` | `json` |
| `DateString` | `date.toDateString` | `date` | `string` |
| `DateValue` | `date.valueOf` | `date` | `primitive value` |
| `DateWithDayOfMonth` | `date.setDate` | `date, day` | `date` |
| `DateWithFullYear` | `date.setFullYear` | `date, year` | `date` |
| `DateWithHours` | `date.setHours` | `date, hours` | `date` |
| `DateWithMilliseconds` | `date.setMilliseconds` | `date, milliseconds` | `date` |
| `DateWithMinutes` | `date.setMinutes` | `date, minutes` | `date` |
| `DateWithMonth` | `date.setMonth` | `date, month` | `date` |
| `DateWithSeconds` | `date.setSeconds` | `date, seconds` | `date` |
| `DateWithTime` | `date.setTime` | `date, time` | `date` |
| `DateWithUTCDayOfMonth` | `date.setUTCDate` | `date, day` | `date` |
| `DateWithUTCFullYear` | `date.setUTCFullYear` | `date, year` | `date` |
| `DateWithUTCHours` | `date.setUTCHours` | `date, hours` | `date` |
| `DateWithUTCMilliseconds` | `date.setUTCMilliseconds` | `date, milliseconds` | `date` |
| `DateWithUTCMinutes` | `date.setUTCMinutes` | `date, minutes` | `date` |
| `DateWithUTCMonth` | `date.setUTCMonth` | `date, month` | `date` |
| `DateWithUTCSeconds` | `date.setUTCSeconds` | `date, seconds` | `date` |
| `DateWithUTCTime` | `date.setUTCTime` | `date, time` | `date` |
| `DateWithYear` | `date.setYear` | `date, year` | `date` |
| `DayOfMonth` | `date.getDate` | `date` | `number` |
| `DayOfWeek` | `date.getDay` | `date` | `number` |
| `FullYear` | `date.getFullYear` | `date` | `number` |
| `GMTString` | `date.toGMTString` | `date` | `string` |
| `Hours` | `date.getHours` | `date` | `number` |
| `ISOString` | `date.toISOString` | `date` | `string` |
| `LocaleDateString` | `date.toLocaleDateString` | `date, ...args` | `string` |
| `LocaleTimeString` | `date.toLocaleTimeString` | `date, ...args` | `string` |
| `Milliseconds` | `date.getMilliseconds` | `date` | `number` |
| `Minutes` | `date.getMinutes` | `date` | `number` |
| `Month` | `date.getMonth` | `date` | `number` |
| `Now` | `Date.now` |  | `date` |
| `ParsedDate` | `Date.parse` | `date` | `number(ms)` |
| `Seconds` | `date.getSeconds` | `date` | `number` |
| `Time` | `date.getTime` | `date` | `number(ms)` |
| `TimeString` | `date.toTimeString` | `date` | `string` |
| `TimezoneOffset` | `date.getTimezoneOffset` | `date` | `number` |
| `UTC` | `Date.UTC` | `...params` | `number(ms)` |
| `UTCDayOfMonth` | `date.getUTCDate` | `date` | `number` |
| `UTCDayOfWeek` | `date.getUTCDay` | `date` | `number` |
| `UTCFullYear` | `date.getUTCFullYear` | `date` | `number` |
| `UTCHours` | `date.getUTCHours` | `date` | `number` |
| `UTCMilliseconds` | `date.getUTCMilliseconds` | `date` | `number` |
| `UTCMinutes` | `date.getUTCMinutes` | `date` | `number` |
| `UTCMonth` | `date.getUTCMonth` | `date` | `number` |
| `UTCSeconds` | `date.getUTCSeconds` | `date` | `number` |
| `UTCString` | `date.toUTCString` | `date` | `string` |
| `Year` | `date.getYear` | `date` | `number` |

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