angular-relative-date-zhtw

WebJar for angular-relative-date-zhtw

License

License

MIT
Categories

Categories

Angular User Interface Web Frameworks
GroupId

GroupId

org.webjars.bower
ArtifactId

ArtifactId

angular-relative-date-zhtw
Last Version

Last Version

0.1.1
Release Date

Release Date

Type

Type

jar
Description

Description

angular-relative-date-zhtw
WebJar for angular-relative-date-zhtw
Project URL

Project URL

http://webjars.org
Source Code Management

Source Code Management

https://github.com/rk87/angular-relative-date

Download angular-relative-date-zhtw

How to add to project

<!-- https://jarcasting.com/artifacts/org.webjars.bower/angular-relative-date-zhtw/ -->
<dependency>
    <groupId>org.webjars.bower</groupId>
    <artifactId>angular-relative-date-zhtw</artifactId>
    <version>0.1.1</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.bower/angular-relative-date-zhtw/
implementation 'org.webjars.bower:angular-relative-date-zhtw:0.1.1'
// https://jarcasting.com/artifacts/org.webjars.bower/angular-relative-date-zhtw/
implementation ("org.webjars.bower:angular-relative-date-zhtw:0.1.1")
'org.webjars.bower:angular-relative-date-zhtw:jar:0.1.1'
<dependency org="org.webjars.bower" name="angular-relative-date-zhtw" rev="0.1.1">
  <artifact name="angular-relative-date-zhtw" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.bower', module='angular-relative-date-zhtw', version='0.1.1')
)
libraryDependencies += "org.webjars.bower" % "angular-relative-date-zhtw" % "0.1.1"
[org.webjars.bower/angular-relative-date-zhtw "0.1.1"]

Dependencies

compile (1)

Group / Artifact Type Version
org.webjars.bower : angular jar [1.0.0,1.3.0)

Project Modules

There are no modules declared in this project.

angular-relative-date

Build Status

AngularJS filter for creating relative, human-readable dates. (zh-TW localized)

Usage

Include angular-relative-date.js in your application.

<script src="angular-relative-date.js"></script>

Add the relativeDate module to your application's dependencies.

angular.module('myApp', ['relativeDate']);

Use the filter by passing it date strings or Date objects.

<script>
angular.module('myApp').controller('MainCtrl', function($scope) {
    $scope.dateString = '2013-09-08';
    $scope.dateObject = new Date();
});
</script>

<p>Date strings work: <strong>{{ dateString | relativeDate }}</strong></p>
<p>And so do <code>Date</code> objects: <strong>{{ dateObject | relativeDate }}</strong></p>

The above example will look something like this:

Date strings work: 1 週前

And so do Date objects: 剛剛

License

Released under the terms of MIT License:

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the 'Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Versions

Version
0.1.1