# @dangvanthanh/vue-clock

> Simple clock using Vue.js

Latest version **0.2.6** (published 2024-08-01) · MIT license · 0 weekly downloads

## Install

```sh
npm install @dangvanthanh/vue-clock
pnpm add @dangvanthanh/vue-clock
yarn add @dangvanthanh/vue-clock
bun add @dangvanthanh/vue-clock
```

## Health

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

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types; pre 1.0.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 0.2.6 |
| Published | 2024-08-01 |
| First published | 2018-12-04 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 26.1 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 45 |
| Author | Dang Van Thanh |
| Maintainers | dangvanthanh |
| Keywords | vue, vue-clock, clock |

## Links

- npm: https://www.npmjs.com/package/@dangvanthanh/vue-clock
- Repository: https://github.com/dangvanthanh/vue-clock
- Homepage: https://github.com/dangvanthanh/vue-clock#readme
- Issues: https://github.com/dangvanthanh/vue-clock/issues
- npm.io page: https://npm.io/package/@dangvanthanh/vue-clock

## Recent versions

- 0.2.6 (latest) — 2024-08-01
- 0.2.5 — 2022-12-26
- 0.2.4 — 2022-12-26
- 0.2.3 — 2021-09-14
- 0.2.1 — 2020-12-15
- 0.2.0 — 2020-12-10
- 0.1.9 — 2020-12-02
- 0.1.8 — 2020-11-27
- 0.1.7 — 2020-09-05
- 0.1.5 — 2020-08-27
- 0.1.4 — 2020-08-26
- 0.1.3 — 2020-08-26
- 0.1.2 — 2020-08-26
- 0.1.1 — 2018-12-04

## README

# Vue Clock

> Simple clock component using Vue.js

![](screenshot.png)

## Install

### CDN

```html
<script src="https://unpkg.com/@dangvanthanh/vue-clock"></script>
```

### NPM

```shell
$ npm install @dangvanthanh/vue-clock --save
```

## Usage

### Vue

```javascript
import Vue from "vue";
import VueClock from "@dangvanthanh/vue-clock";

Vue.use(VueClock);
```

```vue
<template>
  <div class="app">
    <h3>Display all</h3>
    <VueClock />
    <h3>Hidden hour</h3>
    <VueClock :isHour="false"/>
    <h3>Hidden minute and second</h3>
    <VueClock :isMinute="false" :isSecond="false" />
    <h3>With timeZone</h3>
    <VueClock timeZone="'America/New_York'" />
  </div>
</template>

<script>
import VueClock from '@dangvanthanh/vue-clock'

export default {
  components: { VueClock },
}
</script>
```

### Nuxt (or SSR)

```javascript
import Vue from "vue";
import VueClock from "@dangvanthanh/vue-clock";

Vue.component("VueClock", VueClock);
// or
// Vue.use(VueClock);
```

# Props

| Name       | Type      | Default | Description                                             |
| ---------- | --------- | ------- | ------------------------------------------------------- |
| `is24h`    | `Boolean` | `false` | Display 24h or not                                      |
| `isHour`   | `Boolean` | `true`  | Display/hidden hour                                     |
| `isMinute` | `Boolean` | `true`  | Display/hidden minute                                   |
| `isSecond` | `Boolean` | `true`  | Display/hidden second                                   |
| `timeZone` | `String`  | `true`  | [List of Time Zones](https://timezonedb.com/time-zones) |

## License

MIT © [Dang Van Thanh](https://dangthanh.org)

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