title: How to fetch locales asynchronously (nuxt.js + i18n + axios)
body: <p>I'd like to get the location asynchronously. Unfortunately my code causes "Maximum call stack size exceeded" error. How can I do it correctly?</p>
  
  <p>So far I've tried to do this by invoking the axios command, inside the messages object.</p>
  
  <pre><code>~/plugins/i18n.js
  
  import Vue from "vue";
  import VueI18n from "vue-i18n";
  import axios from 'axios';
  
  Vue.use(VueI18n);
  
  export default async ({ app, store }) =&gt; {
      app.i18n = new VueI18n({
      locale: 'fr',
      fallbackLocale: 'en',
      messages: {
          en: await axios.get('https://some-api/en/locale'),
          fr: await axios.get('https://some-api/fr/locale')
      }
  });
  </code></pre>
  
  <p>}</p>
  
  <p>I would like fetch my locales asynchronous, before the page is rendered.</p>