Requirements
Installation
WARNING: The following guide will install a pre-release version of Skeleton v3. Some features may be missing, incomplete, or non-functional at this time. Please report bugs and issues on GitHub or Discord.
1
Create a Project
Use the Svete CLI to generate a new SvelteKit project.
npx sv create --template minimal --types ts my-skeleton-appcd my-skeleton-app
NOTE: If you miss the prompt to install Tailwind, use
npx sv add tailwindcss
to add it retroactively.
2
Install Skeleton
Install the Skeleton core and Svelte component packages.
npm i -D @skeletonlabs/skeleton@next @skeletonlabs/skeleton-svelte@next
3
Configure Tailwind
Open your global stylesheet in /src/app/globals.css
and add the following imports:
@import 'tailwindcss';
@import '@skeletonlabs/skeleton';@import '@skeletonlabs/skeleton/optional/presets';@import '@skeletonlabs/skeleton/themes/cerberus';
4
Set Active Theme
Open /src/app.html
, then set the data-theme
attribute on the HTML tag to define the active theme.
<html data-theme="cerberus">...</html>
Done
Start the dev server using the following command.
npm run dev