This is a fullstack starter template that combines SvelteKit for the frontend and PocketBase as the backend framework.
PocketBase here is not just used as a database, but as a complete backend framework. You can easily extend it to fit your needs:
- Go Extensions → pocketbase.io/docs/go-overview
- JavaScript Extensions → pocketbase.io/docs/js-overview
The project is organized with a clear separation between frontend and backend:
.
├── pb/ # PocketBase backend (Go &/ JavaScript)
├── sv/ # SvelteKit frontend (TypeScript)
├── .gitignore
├── LICENSE
├── package.json
├── package-lock.json
└── README.md
git clone https://github.com/kimmyxpow/svpb.git
cd svpb
npm install
This will install all dependencies in the root and in the sv/
frontend workspace.
Make sure Go is installed, then run:
go install github.com/cortesi/modd/cmd/modd@latest
You may need to add $GOPATH/bin
to your PATH if modd
is not found after install.
npm run dev
Runs both the SvelteKit dev server and PocketBase backend in parallel.
npm run dev:fe
npm run dev:be
By default, PocketBase will run at http://localhost:8090.
You can generate TypeScript types from your PocketBase collections for use in the frontend:
npm run typegen
This will create or update the types in sv/src/lib/pocketbase/generated-types.ts
using your local PocketBase SQLite data.