Use Svelte and Markdown to create beautiful presentations. šŖ
š§ Work in progress š§
git clone https://github.com/mattcroat/svelte-slides.git
npm i
npm run dev
routes/index.md
Slides are separated with ---
representing <hr>
.
# Slide 1
Content
---
# Slide 2
Content
---
You can navigate using ArrowLeft
and ArrowRight
but you can change and extend the behavior inside src/layout.svelte
.
styles/global.css
styles/syntax.css
using Night Owl as the default theme but you can find more Prism themes or create your ownslide.svelte
You can import and use any Svelte component inside the <script>
tag in routes/index.md
.
<script lang="ts">
import Counter from '$lib/components/mdsvex/counter.svelte'
</script>
# Slide
<Counter />
---
You can create custom elements by creating a Svelte component named as the HTML element you want to replace and import and export it inside src/layout.svelte
.
<script context="module">
import h1 from '$lib/components/mdsvex/h1.svelte'
export { h1 }
</script>
---
and turns each slide into a <Slide />
component that is made navigatable by showing and hiding slides and styled using CSS with animations on transitionslib/components/mdsvex/slide.svelte
layout.svelte
component is a special mdsvex
component that wraps everything and has your custom components, styles and navigation logic