fix: old cached articles with cozified links going to an a
route
This commit is contained in:
parent
2cf0e53a47
commit
b3b8777a39
2 changed files with 25 additions and 1 deletions
|
@ -6,4 +6,4 @@ export const SITE_AUTHOR_MASTODON = 'https://social.ayco.io/@ayo'
|
|||
export const SITE_PROJECT_REPO = 'https://github.com/ayoayco/Cozy'
|
||||
export const SITE_DESCRIPTION = 'The Web is Yours.'
|
||||
|
||||
export const VERSION = 'Careless-Carrot'
|
||||
export const VERSION = 'Drooling-Dogs'
|
||||
|
|
24
src/pages/a.astro
Normal file
24
src/pages/a.astro
Normal file
|
@ -0,0 +1,24 @@
|
|||
---
|
||||
/**
|
||||
* NOTE: this page is a fix for old cached articles w/ cozified links going to an `a` route
|
||||
*/
|
||||
import SimpleAddressBar from '../components/SimpleAddressBar.astro'
|
||||
import App from '../layouts/App.astro'
|
||||
import Library from '../components/Library.astro'
|
||||
import Footer from '../components/Footer.astro'
|
||||
|
||||
export const prerender = false
|
||||
const url = Astro.url.searchParams.get('url')
|
||||
return Astro.redirect(`/?url=${url}`)
|
||||
---
|
||||
|
||||
<App article={null}>
|
||||
<SimpleAddressBar url={url} />
|
||||
|
||||
<div>
|
||||
Go to the correct <a href={`/?url=${url}`}>Page</a>
|
||||
</div>
|
||||
|
||||
<Library slot="library" skipSave={true} />
|
||||
<Footer slot="footer" />
|
||||
</App>
|
Loading…
Reference in a new issue