添加前端支持
This commit is contained in:
@@ -1,6 +1,14 @@
|
||||
# sv
|
||||
# Loongyan Photo Album Web
|
||||
|
||||
Everything you need to build a Svelte project, powered by [`sv`](https://github.com/sveltejs/cli).
|
||||
网页相册前端,基于 SvelteKit 构建,支持中英文国际化。
|
||||
|
||||
## 功能特性
|
||||
|
||||
- 📁 相册列表展示
|
||||
- 🖼️ 照片浏览
|
||||
- 🌍 中英文国际化支持
|
||||
- 📱 响应式设计
|
||||
- ⌨️ 键盘导航支持(左右键切换照片,ESC 关闭)
|
||||
|
||||
## Creating a project
|
||||
|
||||
@@ -18,17 +26,24 @@ To recreate this project with the same configuration:
|
||||
pnpm dlx sv@0.12.6 create --template minimal --types jsdoc --add prettier vitest="usages:unit,component" eslint sveltekit-adapter="adapter:auto" devtools-json better-auth="demo:password" mdsvex paraglide="languageTags:en, zh+demo:yes" drizzle="database:sqlite+sqlite:better-sqlite3" --install pnpm web/
|
||||
```
|
||||
|
||||
## Developing
|
||||
## 开发
|
||||
|
||||
Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server:
|
||||
安装依赖并启动开发服务器:
|
||||
|
||||
```sh
|
||||
pnpm install
|
||||
npm run dev
|
||||
|
||||
# or start the server and open the app in a new browser tab
|
||||
# 或自动打开浏览器
|
||||
npm run dev -- --open
|
||||
```
|
||||
|
||||
## API 配置
|
||||
|
||||
本项目需要配合后端 API 使用。默认情况下,API 请求会发送到同源服务器。
|
||||
|
||||
如果需要配置 API 地址,请修改 `src/lib/api/client.js` 中的 `API_BASE` 常量。
|
||||
|
||||
## Building
|
||||
|
||||
To create a production version of your app:
|
||||
|
||||
Reference in New Issue
Block a user