Skip to content

Commit f748b8c

Browse files
committed
Update README
1 parent 2002fef commit f748b8c

File tree

1 file changed

+35
-38
lines changed

1 file changed

+35
-38
lines changed

sveltekit/README.md

Lines changed: 35 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,38 +1,35 @@
1-
# create-svelte
2-
3-
Everything you need to build a Svelte project, powered by [`create-svelte`](https://github.com/sveltejs/kit/tree/main/packages/create-svelte).
4-
5-
## Creating a project
6-
7-
If you're seeing this, you've probably already done this step. Congrats!
8-
9-
```bash
10-
# create a new project in the current directory
11-
npx sv create
12-
13-
# create a new project in my-app
14-
npx sv create my-app
15-
```
16-
17-
## Developing
18-
19-
Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server:
20-
21-
```bash
22-
npm run dev
23-
24-
# or start the server and open the app in a new browser tab
25-
npm run dev -- --open
26-
```
27-
28-
## Building
29-
30-
To create a production version of your app:
31-
32-
```bash
33-
npm run build
34-
```
35-
36-
You can preview the production build with `npm run preview`.
37-
38-
> To deploy your app, you may need to install an [adapter](https://svelte.dev/docs/kit/adapters) for your target environment.
1+
---
2+
title: SvelteKit + Transformers.js Server Template
3+
emoji: 🧩
4+
colorFrom: yellow
5+
colorTo: red
6+
sdk: docker
7+
pinned: false
8+
app_port: 4173
9+
---
10+
11+
# sveltekit
12+
13+
This project, bootstrapped using [`create-svelte`](https://github.com/sveltejs/kit/tree/main/packages/create-svelte), demonstrates how to use `@huggingface/transformers` in [SvelteKit](https://svelte.dev/).
14+
15+
## Instructions
16+
17+
1. Clone the repository:
18+
```sh
19+
git clone https://github.com/huggingface/transformers.js-examples.git
20+
```
21+
2. Change directory to the `sveltekit` project:
22+
```sh
23+
cd transformers.js-examples/sveltekit
24+
```
25+
3. Install the dependencies:
26+
```sh
27+
npm install
28+
```
29+
4. Run the development server:
30+
```sh
31+
npm run dev
32+
```
33+
5. Open [http://localhost:5173](http://localhost:5173) with your browser to see the result.
34+
35+
6. You can start editing the page by modifying `src/routes/+page.svelte` (SvelteKit) and `src/routes/api/classify/+server.js` (Transformers.js). The page auto-updates as you edit the file.

0 commit comments

Comments
 (0)