Skip to main content
Introducing packages.sweber.dev
Documentation menuExamples

Examples

Complete starter projects for Vite, Next.js, SvelteKit and Astro.

Four small projects in the examples folder show the widget in a real framework. Each one reads its own CHANGELOG.md, writes public/changelog.json (or static/ in SvelteKit) before the build, and embeds the widget with announce and search.

FolderFrameworkHow the widget is added
viteViteweb component, imported in src/main.ts
nextjsNext.js 15, App RouterWhatsNew from @sweberdev/derivative-react in app/layout.tsx
sveltekitSvelteKit, Svelte 5web component, imported in onMount
astroAstro 5web component, imported in a page <script>

Copy a folder, run pnpm install and pnpm dev. The examples are built against the published package on every change, so they keep working. For details see the guides for React, Vue and Svelte.