1
0
Fork 0
mirror of https://github.com/mealie-recipes/mealie.git synced 2025-07-24 07:39:41 +02:00

fix: eslint errors and failing tests (#2078)

* fix eslint errors

* fix failing tests
This commit is contained in:
Hayden 2023-01-29 13:01:41 -09:00 committed by GitHub
parent 7c766af848
commit 5dc253799d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 35 additions and 29 deletions

19
frontend/tests/utils.ts Normal file
View file

@ -0,0 +1,19 @@
import VueI18n from "vue-i18n";
import Vue from "vue";
Vue.use(VueI18n)
function loadEnLocales() {
// eslint-disable-next-line @typescript-eslint/no-var-requires
return require("../lang/messages/en-US.json") as Record<string, string>;
}
export function stubI18n() {
const i18n = new VueI18n({
locale: "en-US",
messages: {
"en-US": loadEnLocales(),
},
})
return i18n
}