From a5e4c607967f13911c83cc349eac283e655e454a Mon Sep 17 00:00:00 2001 From: Vicente Olivert Riera Date: Mon, 30 Oct 2023 12:09:44 +0900 Subject: [PATCH] vue/promql-query: Use same delimiters as the Vue app Using different delimiters in different components can be error prone and confusing. Is better to stick to one kind of delimiters and use it always, for the previous reasons and also for consistency. --- promgen/static/js/promgen.vue.js | 1 + promgen/templates/promgen/vue/promql_query.html | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/promgen/static/js/promgen.vue.js b/promgen/static/js/promgen.vue.js index 2f1b5f2c7..2a10257e2 100644 --- a/promgen/static/js/promgen.vue.js +++ b/promgen/static/js/promgen.vue.js @@ -188,6 +188,7 @@ Vue.filter("time", function (value, fmtstr = "yyyy-MM-dd HH:mm:ss") { }); Vue.component("promql-query", { + delimiters: ['[[', ']]'], props: ["href", "query", "max"], data: function () { return { diff --git a/promgen/templates/promgen/vue/promql_query.html b/promgen/templates/promgen/vue/promql_query.html index 908478a58..2afc4a11f 100644 --- a/promgen/templates/promgen/vue/promql_query.html +++ b/promgen/templates/promgen/vue/promql_query.html @@ -1,3 +1,3 @@ - {{ count | localize }} + [[ count | localize ]]