43 lines
1.1 KiB
Markdown
43 lines
1.1 KiB
Markdown
# sv
|
|
|
|
Everything you need to build a Svelte project, powered by [`sv`](https://github.com/sveltejs/cli).
|
|
|
|
## Creating a project
|
|
|
|
If you're seeing this, you've probably already done this step. Congrats!
|
|
|
|
```sh
|
|
# create a new project
|
|
npx sv create my-app
|
|
```
|
|
|
|
To recreate this project with the same configuration:
|
|
|
|
```sh
|
|
# recreate this project
|
|
bun x sv create --template minimal --types ts --add prettier eslint vitest="usages:unit,component" playwright tailwindcss="plugins:typography" sveltekit-adapter="adapter:node" devtools-json drizzle="database:postgresql+postgresql:postgres.js+docker:no" better-auth="demo:password,github" --install bun .
|
|
```
|
|
|
|
## Developing
|
|
|
|
This project now requires Bun at runtime because the server uses Bun SQL. Start the development server with:
|
|
|
|
```sh
|
|
bun run dev
|
|
|
|
# or start the server and open the app in a new browser tab
|
|
bun run dev -- --open
|
|
```
|
|
|
|
## Building
|
|
|
|
To create a production version of your app:
|
|
|
|
```sh
|
|
bun run build
|
|
```
|
|
|
|
You can preview the production build with `bun run preview`.
|
|
|
|
> To deploy your app, you may need to install an [adapter](https://svelte.dev/docs/kit/adapters) for your target environment.
|