From b1d37b3e3ac34ea2554cf466bfbe65774cdfe7b2 Mon Sep 17 00:00:00 2001 From: Marcel Schneider Date: Fri, 28 Apr 2017 11:46:43 +0200 Subject: [PATCH] Use watcher instead of event for meal loading --- src/App.vue | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/App.vue b/src/App.vue index a6ec2ef..b4f7714 100644 --- a/src/App.vue +++ b/src/App.vue @@ -2,11 +2,11 @@

Essen in Göttingen

- Wo? - Wann? @@ -43,6 +43,10 @@ export default { when: '' + new Date().getDay() } }, + watch: { + 'where': 'updateRoute', + 'when': 'updateRoute' + }, methods: { updateRoute () { this.$router.push(`/${this.where}/${this.when}`)