You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-06-15 23:00:36 +02:00
Applied prettier to code base
This commit is contained in:
@ -1,10 +1,9 @@
|
||||
const moment = require('moment');
|
||||
const moment = require("moment");
|
||||
|
||||
class Time {
|
||||
|
||||
constructor() {
|
||||
this.dateFormat_ = 'DD/MM/YYYY';
|
||||
this.timeFormat_ = 'HH:mm';
|
||||
this.dateFormat_ = "DD/MM/YYYY";
|
||||
this.timeFormat_ = "HH:mm";
|
||||
}
|
||||
|
||||
dateFormat() {
|
||||
@ -24,7 +23,7 @@ class Time {
|
||||
}
|
||||
|
||||
dateTimeFormat() {
|
||||
return this.dateFormat() + ' ' + this.timeFormat();
|
||||
return this.dateFormat() + " " + this.timeFormat();
|
||||
}
|
||||
|
||||
unix() {
|
||||
@ -44,15 +43,25 @@ class Time {
|
||||
}
|
||||
|
||||
unixMsToIso(ms) {
|
||||
return moment.unix(ms / 1000).utc().format('YYYY-MM-DDTHH:mm:ss.SSS') + 'Z';
|
||||
return (
|
||||
moment
|
||||
.unix(ms / 1000)
|
||||
.utc()
|
||||
.format("YYYY-MM-DDTHH:mm:ss.SSS") + "Z"
|
||||
);
|
||||
}
|
||||
|
||||
unixMsToIsoSec(ms) {
|
||||
return moment.unix(ms / 1000).utc().format('YYYY-MM-DDTHH:mm:ss') + 'Z';
|
||||
return (
|
||||
moment
|
||||
.unix(ms / 1000)
|
||||
.utc()
|
||||
.format("YYYY-MM-DDTHH:mm:ss") + "Z"
|
||||
);
|
||||
}
|
||||
|
||||
unixMsToLocalDateTime(ms) {
|
||||
return moment.unix(ms / 1000).format('DD/MM/YYYY HH:mm');
|
||||
return moment.unix(ms / 1000).format("DD/MM/YYYY HH:mm");
|
||||
}
|
||||
|
||||
formatMsToLocal(ms, format = null) {
|
||||
@ -71,9 +80,8 @@ class Time {
|
||||
sleep(seconds) {
|
||||
return this.msleep(seconds * 1000);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
const time = new Time();
|
||||
|
||||
module.exports = { time };
|
||||
module.exports = { time };
|
||||
|
Reference in New Issue
Block a user