Skip to content

Commit

Permalink
Add Switch.version.wasm3
Browse files Browse the repository at this point in the history
  • Loading branch information
TooTallNate committed Oct 5, 2023
1 parent 399b631 commit 8ad22c4
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/great-stingrays-sparkle.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'nxjs-runtime': patch
---

Add `Switch.version.wasm3`
1 change: 1 addition & 0 deletions packages/runtime/src/switch.ts
Original file line number Diff line number Diff line change
Expand Up @@ -370,6 +370,7 @@ export interface Versions {
png: string;
quickjs: string;
turbojpeg: string;
wasm3: string;
webp: string;
}

Expand Down
1 change: 1 addition & 0 deletions source/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -478,6 +478,7 @@ int main(int argc, char *argv[])
JS_SetPropertyStr(ctx, version_obj, "png", JS_NewString(ctx, PNG_LIBPNG_VER_STRING));
JS_SetPropertyStr(ctx, version_obj, "quickjs", JS_NewString(ctx, QUICKJS_VERSION));
JS_SetPropertyStr(ctx, version_obj, "turbojpeg", JS_NewString(ctx, LIBTURBOJPEG_VERSION));
JS_SetPropertyStr(ctx, version_obj, "wasm3", JS_NewString(ctx, M3_VERSION));
const int webp_version = WebPGetDecoderVersion();
char webp_version_str[12];
snprintf(webp_version_str, 12, "%d.%d.%d", (webp_version >> 16) & 0xFF, (webp_version >> 8) & 0xFF, webp_version & 0xFF);
Expand Down

0 comments on commit 8ad22c4

Please sign in to comment.