From 22794f5f9f6081bd9bf790e69e4a0453f9ff4abd Mon Sep 17 00:00:00 2001 From: sundowndev Date: Wed, 30 Oct 2019 15:16:42 +0100 Subject: [PATCH] refactor(client): ScoreScreen component Sort messages array --- client/src/components/ScoreScreen.vue | 3 +++ 1 file changed, 3 insertions(+) diff --git a/client/src/components/ScoreScreen.vue b/client/src/components/ScoreScreen.vue index bade2d1..2259dd2 100644 --- a/client/src/components/ScoreScreen.vue +++ b/client/src/components/ScoreScreen.vue @@ -35,6 +35,9 @@ export default Vue.extend({ return text[0] !== undefined ? text[0].msg : ''; }, }, + created() { + this.messages.sort((a, b) => b.min - a.min); + }, });