File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ ```
2+ pnpm install
3+ pnpm run dev
4+ ```
5+
6+ ```
7+ open http://localhost:5173
8+ ```
Original file line number Diff line number Diff line change @@ -14,8 +14,11 @@ globalThis.tryCatch = (fn: () => any) => {
1414 } catch ( err ) {
1515 if ( ! ( err instanceof Error ) ) {
1616 if ( err instanceof Object ) {
17- return { error : JSON . stringify ( err ) } ;
17+ err = JSON . stringify ( err ) ;
1818 }
19+
20+ // @ts -expect-error
21+ err = new Error ( err || "no error message" ) ;
1922 }
2023
2124 return { error : err } ;
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ FROM golang:1.23 AS build-go
1212WORKDIR /app
1313COPY . .
1414RUN go mod download
15- RUN GOOS=js GOARCH=wasm go build -ldflags= '-s -w' - o ./bin/app.wasm ./pkg/main.go
15+ RUN GOOS=js GOARCH=wasm go build -o ./bin/app.wasm ./pkg/main.go
1616
1717FROM base AS build
1818COPY . .
@@ -21,7 +21,6 @@ COPY --from=build-go /app/bin/app.wasm /app/bin/app.wasm
2121RUN pnpm run build:js
2222
2323FROM base
24- RUN apt update && apt install curl -y
2524COPY migrations migrations
2625COPY package.json package.json
2726COPY wrangler.toml wrangler.toml
@@ -30,6 +29,5 @@ COPY --from=build /app/dist .
3029COPY --from=build-go /app/bin bin
3130
3231EXPOSE 5173
33- HEALTHCHECK --interval=30s --timeout=30s --retries=3 --start-period=3s --start-interval=150ms CMD curl -f http://localhost:5173/health || exit 1
3432RUN pnpm add wrangler
3533CMD ["pnpm" , "start" ]
Original file line number Diff line number Diff line change 1+ ```
2+ pnpm install
3+ pnpm run dev
4+ ```
5+
6+ ```
7+ open http://localhost:5173
8+ ```
Original file line number Diff line number Diff line change 2828 "@cloudflare/vite-plugin" : " ^1.12.0" ,
2929 "@cloudflare/vitest-pool-workers" : " ^0.8.67" ,
3030 "@faker-js/faker" : " ^10.0.0" ,
31+ "@types/bun" : " ^1.2.21" ,
3132 "@types/node" : " ^24.3.0" ,
3233 "vite" : " ^7.1.3" ,
3334 "vite-plugin-watch" : " ^0.3.1" ,
You can’t perform that action at this time.
0 commit comments