I have some files that return simple data, like mutation.js for vuex but generally they are just like this:
export default {
...
someFunction() {}
...
}
Right now, I would like to access this.
so I can use the vue-i18n translation like this.$t('TRANS_TOKEN')
but for some reason I am not able to use this.
I am thinking about including vue in this file as: import vue from 'vue'
and probably do vue.$t(..)
if it works but I tried it and it doesn't