Fixing shortlink redirection
This commit is contained in:
@@ -59,6 +59,19 @@ const {
|
|||||||
<link rel="manifest" href="site.webmanifest" />
|
<link rel="manifest" href="site.webmanifest" />
|
||||||
<link rel="sitemap" href="/sitemap-index.xml" />
|
<link rel="sitemap" href="/sitemap-index.xml" />
|
||||||
<ClientRouter />
|
<ClientRouter />
|
||||||
|
|
||||||
|
<script is:inline>
|
||||||
|
// Runs immediately on every hard page load
|
||||||
|
const url = new URL(window.location.href);
|
||||||
|
|
||||||
|
if (url.searchParams.has('noloop')) {
|
||||||
|
url.searchParams.delete('noloop');
|
||||||
|
|
||||||
|
// Replace the URL in the address bar without adding to history
|
||||||
|
const cleanUrl = url.pathname + url.search + url.hash;
|
||||||
|
window.history.replaceState({}, '', cleanUrl);
|
||||||
|
}
|
||||||
|
</script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<Header client:load />
|
<Header client:load />
|
||||||
|
|||||||
Reference in New Issue
Block a user