forked from AkkomaGang/akkoma-fe
Merge branch 'feature/custom-timestamps' into 'develop'
Add a custom timeago.json for shorter timestamps, for example '15s' instead of '15 seconds ago' See merge request !80
This commit is contained in:
commit
bf7190bfca
2 changed files with 11 additions and 1 deletions
|
@ -24,7 +24,7 @@ Vue.use(VueRouter)
|
||||||
Vue.use(VueTimeago, {
|
Vue.use(VueTimeago, {
|
||||||
locale: 'en-US',
|
locale: 'en-US',
|
||||||
locales: {
|
locales: {
|
||||||
'en-US': require('vue-timeago/locales/en-US.json')
|
'en-US': require('../static/timeago.json')
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
10
static/timeago.json
Normal file
10
static/timeago.json
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
[
|
||||||
|
"now",
|
||||||
|
["%ss", "%ss"],
|
||||||
|
["%smin", "%smin"],
|
||||||
|
["%sh", "%sh"],
|
||||||
|
["%sd", "%sd"],
|
||||||
|
["%sw", "%sw"],
|
||||||
|
["%sm", "%sm"],
|
||||||
|
["%sy", "%sy"]
|
||||||
|
]
|
Loading…
Reference in a new issue