Installation
Install the component
Run the following command to install the component and its dependencies:
Import the component
Import the component into your Svelte file:
Showcase
A full-bleed gallery featuring parallax transitions and a synchronized thumbnail navigator.
npx @motion-core/cli add slideshownpx @motion-core/cli add slideshowpnpm dlx @motion-core/cli add slideshowpnpm dlx @motion-core/cli add slideshowbunx @motion-core/cli add slideshowbunx @motion-core/cli add slideshowyarn dlx @motion-core/cli add slideshowyarn dlx @motion-core/cli add slideshowimport { Slideshow } from "$lib/motion-core";import { Slideshow } from "$lib/motion-core";


<script lang="ts">
import { Slideshow } from "motion-core";
const images = [
{
src: "/images/photos/sample-image-1.webp",
alt: "Alt 1",
},
{
src: "/images/photos/sample-image-2.webp",
alt: "Alt 2",
},
{
src: "/images/photos/sample-image-3.webp",
alt: "Alt 3",
},
];
</script>
<Slideshow class="h-full min-h-96 w-full" {images} />
<script lang="ts">
import { Slideshow } from "motion-core";
const images = [
{
src: "/images/photos/sample-image-1.webp",
alt: "Alt 1",
},
{
src: "/images/photos/sample-image-2.webp",
alt: "Alt 2",
},
{
src: "/images/photos/sample-image-3.webp",
alt: "Alt 3",
},
];
</script>
<Slideshow class="h-full min-h-96 w-full" {images} />
| Prop | Type | Default |
|---|---|---|
images | {src: string, alt?: string}[] | — |
class | string | "" |