From bcdd5bfee03a91f3ca9583b88e2c6a22709067f6 Mon Sep 17 00:00:00 2001 From: Adrien Foulon <6115458+Tofandel@users.noreply.github.com> Date: Fri, 14 Jan 2022 15:40:22 +0100 Subject: [PATCH] Add timeout to init payline after script loaded For some reason Payline takes some time, because if it's initialised within less than 3ms of the script loaded it will initialise but display a blank page A timeout fixes the issue correctly --- src/component/VuePaylineWrapper.vue | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/component/VuePaylineWrapper.vue b/src/component/VuePaylineWrapper.vue index 92cd5a8..2b56832 100644 --- a/src/component/VuePaylineWrapper.vue +++ b/src/component/VuePaylineWrapper.vue @@ -69,7 +69,9 @@ export default { }, payline(v) { if (v) { - this.initPayline(this.token); + setTimeout(() => { + this.initPayline(this.token); + }, 15); } } },