Skip to content

Commit

Permalink
update README
Browse files Browse the repository at this point in the history
  • Loading branch information
vanvuongngo committed Sep 11, 2023
1 parent 5137bfa commit 73f539d
Showing 1 changed file with 23 additions and 21 deletions.
44 changes: 23 additions & 21 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Qwik City App as wasm with Fermyon Spin
# Qwik City App as WASM with Fermyon Spin

- [Fermyon Spin](https://www.fermyon.com/)
- [Qwik Docs](https://qwik.builder.io/)
Expand All @@ -7,45 +7,47 @@
- [@QwikDev](https://twitter.com/QwikDev)
- [Vite](https://vitejs.dev/)

---
## Prerequisites

Getting started with fermyon spin

Install spin
Install `spin`

```sh
curl https://developer.fermyon.com/downloads/install.sh | bash
```

Install `pnpm` (optional)

```sh
spin new --template
npm install -g pnpm
```

````
HTTP base: /
HTTP path: /...
```
If you do not install `pnpm` then you have to modify `component.build.command` in the `spin.toml` file.

## Installing the Spin application template

```sh
cd MY_APP
spin template install --git https://github.com/vanvuongngo/qwik-wasm.git --upgrade
```

extend spin.toml config (at the end)
## Use template to create a new Spin application

```toml
[component.build]
command = "pnpm build" # or `npm run build`
```sh
spin new qwik-frontend <project-name>
```

Optional: if you want to use `pnpm`
choose

```
HTTP base: /
HTTP path: /...
```

```sh
npm install -g pnpm
cd <project-name>
```

start your Qwik WASM
build your Qwik app and start your Spin app

```sh
spin build --up
```
spin up --build
```
````

0 comments on commit 73f539d

Please sign in to comment.