egoist / vue-timeago

A timeago component for Vue.
https://vue-timeago.egoist.sh
MIT License
729 stars 104 forks source link

Component loads english first? #138

Closed Tobeyforce closed 3 years ago

Tobeyforce commented 3 years ago

When I use the component it always starts in english and then blips over to whatever locale I set to use. This looks quite terrible to the user, how can I prevent this? Why is it going to english first and then to my locale (in this case swedish) My settings:

import Vue from 'vue'
import VueTimeago from 'vue-timeago'

Vue.use(VueTimeago, {
    name: 'timeago', // Component name, `Timeago` by default
    locale: 'sv',
    locales: {
      'sv': require('date-fns/locale/sv')
    }
  })
Tobeyforce commented 3 years ago

My apologies, a proper restart of my devserver fixed it. Not sure what the problem was, could've been cache or similar.