# shortdate

> get short date

Latest version **2.0.0** (published 2019-10-11) · MIT license · 0 weekly downloads

## Install

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

## 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 | 2.0.0 |
| Published | 2019-10-11 |
| First published | 2015-01-08 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 7.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | coderaiser |
| Maintainers | coderaiser |
| Keywords | date |

## Links

- npm: https://www.npmjs.com/package/shortdate
- Repository: https://github.com/coderaiser/shortdate
- Issues: https://github.com/coderaiser/shortdate/issues
- npm.io page: https://npm.io/package/shortdate

## 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

- 2.0.0 (latest) — 2019-10-11
- 1.2.0 — 2016-02-20
- 1.1.0 — 2016-02-19
- 1.0.1 — 2015-01-08
- 1.0.0 — 2015-01-08

## README

# Shortdate [![License][LicenseIMGURL]][LicenseURL] [![NPM version][NPMIMGURL]][NPMURL] [![Dependency Status][DependencyStatusIMGURL]][DependencyStatusURL] [![Build Status][BuildStatusIMGURL]][BuildStatusURL] [![Coverage Status][CoverageIMGURL]][CoverageURL]

Get short date. For browser and node.

## Install

```
npm i shortdate
```

## How to use?
`shortdate` uses arguments:
- `date` (optional)
- `options` (optional):
    - `sep` - separator
    - `order` - "big", "middle", "little" ([endian types][EndianTypes]);

```js
var shortdate = require('shortdate');

shortdate();
// returns
'2015.01.08'

shortdate(new Date('9-9'));
// returns
'2001.09.09'

shortdate(new Date(), {
    sep: '/'
});
// returns
'2016/02/20'

shortdate(new Date(), {
    order: 'little'
});
// returns
'20.02.2016'
```

## License

MIT

[NPMIMGURL]:                https://img.shields.io/npm/v/shortdate.svg?style=flat
[BuildStatusIMGURL]:        https://img.shields.io/travis/coderaiser/shortdate/master.svg?style=flat
[DependencyStatusIMGURL]:   https://img.shields.io/david/coderaiser/shortdate.svg?style=flat
[LicenseIMGURL]:            https://img.shields.io/badge/license-MIT-317BF9.svg?style=flat
[NPMURL]:                   https://npmjs.org/package/shortdate "npm"
[BuildStatusURL]:           https://travis-ci.org/coderaiser/shortdate  "Build Status"
[DependencyStatusURL]:      https://david-dm.org/coderaiser/shortdate "Dependency Status"
[LicenseURL]:               https://tldrlegal.com/license/mit-license "MIT License"

[CoverageURL]:              https://coveralls.io/github/coderaiser/shortdate?branch=master
[CoverageIMGURL]:           https://coveralls.io/repos/coderaiser/shortdate/badge.svg?branch=master&service=github

[EndianTypes]:              https://en.wikipedia.org/wiki/Date_format_by_country

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