(bug) fix refactoring issues

This commit is contained in:
Andrea Vos 2024-01-29 18:47:11 +01:00
parent ea506eabb7
commit 2b3ddd4a83
2 changed files with 3 additions and 3 deletions

View File

@ -36,7 +36,7 @@ export default ({ app, store }) => {
if (app.$config.locale !== '_') { if (app.$config.locale !== '_') {
yield [app.$config.locale, process.env.LOCALES[app.$config.locale]]; yield [app.$config.locale, process.env.LOCALES[app.$config.locale]];
} }
for (const [locale, localeDescription] in Object.entries(process.env.LOCALES)) { for (const [locale, localeDescription] of Object.entries(process.env.LOCALES)) {
if (locale !== app.$config.locale) { if (locale !== app.$config.locale) {
yield [locale, localeDescription]; yield [locale, localeDescription];
} }

View File

@ -33,9 +33,9 @@ import parseMarkdown from '../src/parseMarkdown.js';
import Columnist from 'avris-columnist'; import Columnist from 'avris-columnist';
export default { export default {
async asyncData({ route }) { async asyncData({ route, app }) {
const content = (await import(`../data/blog/${route.params.slug || route.meta[0].slug}.md`)).default; const content = (await import(`../data/blog/${route.params.slug || route.meta[0].slug}.md`)).default;
return parseMarkdown(content, this.$translator); return parseMarkdown(content, app.$translator);
}, },
data() { data() {
return { return {