@shadcn-svelte/registry
v0.1.1
Published
sv add-on that scaffolds a shadcn-svelte custom registry template
Readme
@shadcn-svelte/registry
sv community add-on that scaffolds a shadcn-svelte custom registry into an existing SvelteKit project.
Usage
# add it during project creation
npx sv create my-project --add @shadcn-svelte/registry
# or add it afterwards
npx sv add @shadcn-svelte/registryThis add-on:
- depends on the official
tailwindcssadd-on - writes
registry.jsonand the example registry sources under$lib/registry - adds
cnhelpers, theme CSS, and a registry preview page (optional) - installs the packages needed to author and build a registry
- adds a
build:registryscript
Options
demo
Include the registry preview page.
Default: true
npx sv add @shadcn-svelte/registry="demo:true"Local development
## create a new minimal project in the `demo` directory
pnpm demo:create
## build and add this add-on to the demo project
pnpm demo:add
## run the tests
pnpm testYou can also install a local build into any project with:
pnpx sv add file:../path/to/registryBuilding the registry (in a generated project)
pnpm build:registryRegistry JSON files are written to static/r by default and can be served from your SvelteKit app.
