From 4238831aa0d36ee08d65e5ae2aece6a5c5d6b6fa Mon Sep 17 00:00:00 2001 From: Philo Hermans Date: Fri, 2 Aug 2024 12:52:55 +0200 Subject: [PATCH] Add #[Url] attribute support Fixes #21 --- js/wire-extender.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/js/wire-extender.js b/js/wire-extender.js index bdb7543..f6d078a 100644 --- a/js/wire-extender.js +++ b/js/wire-extender.js @@ -30,7 +30,10 @@ function getLivewireUpdateUri() function getEmbedUri() { - return document.querySelector('[data-embed-uri]')?.getAttribute('data-embed-uri') ?? getUri('livewire/embed'); + const base = document.querySelector('[data-embed-uri]')?.getAttribute('data-embed-uri') ?? getUri('livewire/embed'); + const queryString = window.location.search; + + return base + queryString; } function injectLivewire()