ahora voy a por el título

pull/7/head
Borja Robert 2 years ago
parent ca9d7510e8
commit 57dc4d50fd

@ -5,7 +5,7 @@
import Preview from '$lib/preview/Preview.svelte'; import Preview from '$lib/preview/Preview.svelte';
const slug = data.slug; const slug = data.slug;
const templateIndex = templates.map((e) => e.name).indexOf(slug); /** @type {number|undefined} */ const templateIndex = templates.map((e) => e.name).indexOf(slug);
</script> </script>
<svelte:head> <svelte:head>
@ -18,7 +18,11 @@
<div class="main"> <div class="main">
<section class="form"><Form /></section> <section class="form"><Form /></section>
<section class="preview"><Preview {templateIndex} /></section> {#if templateIndex !== undefined}
<section class="preview">
<Preview {templateIndex} />
</section>
{/if}
</div> </div>
<style> <style>

Loading…
Cancel
Save