mirror of
https://github.com/cupcakearmy/nicco.io.git
synced 2024-12-22 08:06:29 +00:00
fixes
This commit is contained in:
parent
14e9772122
commit
95fb377cc8
@ -27,9 +27,7 @@
|
||||
const cl = Cloudinary.new({ cloud_name: 'cupcakearmy' })
|
||||
const cleaned = src.replace('https://api.nicco.io', '/nicco')
|
||||
const all = { ...defaultOptions, ...options }
|
||||
console.log(all)
|
||||
attrs = cl.imageTag(cleaned, all).attributes()
|
||||
console.log(attrs)
|
||||
})
|
||||
</script>
|
||||
|
||||
|
@ -1,18 +1,20 @@
|
||||
<script context="module">
|
||||
export async function preload(page) {
|
||||
return {
|
||||
...(await this.fetch('/api/posts.json').then((res) => res.json())),
|
||||
redirected: page.query.old !== undefined,
|
||||
}
|
||||
return this.fetch('/api/posts.json').then((res) => res.json())
|
||||
}
|
||||
</script>
|
||||
|
||||
<script>
|
||||
import { onMount } from 'svelte'
|
||||
import SimplePage from '../../components/SimplePage.svelte'
|
||||
import PostPreview from '../../components/PostPreview.svelte'
|
||||
|
||||
export let data
|
||||
export let redirected
|
||||
export let redirected = false
|
||||
|
||||
onMount(() => {
|
||||
redirected = new URL(location.href).searchParams.has('old')
|
||||
})
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
Loading…
Reference in New Issue
Block a user