Light JSInterop wrapper for moment.js
Add AST Maven Repo
allprojects {
repositories {
...
maven { url 'https://maven.ascend-tech.us/repo' }
}
}
Add Dependency:
compile 'us.ascendtech:momentjs:0.1.9'
compile 'us.ascendtech:momentjs:0.1.9:sources'
Add JitPack
<repositories>
<repository>
<id>AST Maven</id>
<url>https://maven.ascend-tech.us/repo</url>
</repository>
</repositories>
Add Dependency
<dependency>
<groupId>us.ascendtech</groupId>
<artifactId>momentjs</artifactId>
<version>0.1.9</version>
</dependency>
<dependency>
<groupId>us.ascendtech</groupId>
<artifactId>momentjs</artifactId>
<version>0.1.9</version>
<classifier>sources</classifier>
</dependency>
Add dependency to gwt.xml
<inherits name="us.ascendtech.MomentJS"/>
double year = new MomentJS().year();
String formattedDate = new MomentJS().format("MM-DD-YYYY");