Modifying script loading to accommodate the upcoming release of Svelte 5. The on:load event for scripts placed inside <svelte:head> does not fire in Svelte 5 as a result of this bug:
https://github.com/sveltejs/svelte/issues/8301
Instead of loading the Cloudfare Turnstile script in <svelte:head>, load the script dynamically during mount. This is functionally equivalent to using <svelte:head> but accommodates an operational load event handler. If Svelte 5 resolves Issue 8301, this is not needed.
Fixes: #22
Modifying script loading to accommodate the upcoming release of Svelte 5. The
on:load
event for scripts placed inside<svelte:head>
does not fire in Svelte 5 as a result of this bug: https://github.com/sveltejs/svelte/issues/8301Instead of loading the Cloudfare Turnstile script in
<svelte:head>
, load the script dynamically during mount. This is functionally equivalent to using<svelte:head>
but accommodates an operational load event handler. If Svelte 5 resolves Issue 8301, this is not needed.This pull request can be reviewed on