vue-moment-jalaali

Jalaali Moment.js filters for your Vue.js project
9,166 56
Install
npm install vue-moment-jalaali
Latest Version:2.0.0
Older releases:1
License:MIT
Last Updated:Aug 2, 2017
Links: GitHub  ·  npm
Maintainer: saman

vue-moment-jalaali

Jalaali Moment.js filters for your Vue.js project. This project is based on [vue-moment] (https://github.com/brockpetrie/vue-moment) and [moment-jalaali] (https://github.com/jalaali/moment-jalaali).

Installation

You can install it via NPM:

npm install vue-moment-jalaali

And require plugin like so:

Vue.use(require('vue-moment-jalaali'));

or load vue-moment-jalaali.min.js along with moment-jalaali.js the old fashioned way.

Usage

Simply set moment as the filtering function and you're good to go. At least one argument is expected, which the filter assumes to be a format string if the argument doesn't match any of the other filtering methods.

Vue.js 2.x.x

<span>{{ someDate | moment("jYYYY/jM/jD HH:mm") }}</span>
<!-- or create a new date from 'now' -->
<span>{{ new Date() | moment("jYYYY/jM/jD HH:mm") }}</span>

Vue.js 1.x.x

<span>{{ someDate | moment "jYYYY/jM/jD HH:mm" }}</span>
<!-- or create a new date from 'now' -->
<span>{{ new Date() | moment "jYYYY/jM/jD HH:mm" }}</span>

For more information, usage and format, you can see these repositories:

Related Packages

vue3-jalali-moment

jalali(khorshidi, shamsi, شمسی, خورشیدی, جلالی) filters for your Vue.js project

956 0
vue-moment

Handy Moment.js filters for your Vue.js project

3,393,663 1,305
vue-moment-tz

Handy Moment-timezone.js filters for your Vue.js project.

14,407 0
@rah-emil/vue-moment

Handy Moment.js filters for your Vue.js project

13,540 1
vue-moment-v3

vue-moment for vue.js v3

9,291 0

Version History

Version Released Vue License
2.0.0 MIT
1.0.0 ^1.x.x MIT