From 7c2641bc8df3b5757c9fb86e0af4623d0e27b0ed Mon Sep 17 00:00:00 2001 From: Max Desiatov Date: Tue, 17 May 2022 14:59:01 +0100 Subject: [PATCH 1/4] Bump version to 0.15.0, update `CHANGELOG.md` --- CHANGELOG.md | 27 +++++++++++++++++++++++++++ Example/package-lock.json | 2 +- package-lock.json | 4 ++-- package.json | 2 +- 4 files changed, 31 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 34864d1d8..a759853b0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,30 @@ +# 0.15.0 (17 May 2022) + +This is a major release that adds new features and fixes issues. Specifically: +* `BigInt` and `BigInt`-based `JSTypedArray` types are now supported. Now, when passing `Int64` function from Swift, +it will be mapped to `BigInt` on JavaScript side. +* `constructor` property on `JSBridgedClass` is now optional, which allows bridging JavaScript classes that aren't +available in every browser. +* JavaScriptKit runtime files are now supplied as SwiftPM resources. This allows us to resolve a long-standing issue +in `carton` that could lead to a version mismatch between JavaScriptKit dependency in `Package.swift` or +`Package.resolved` and supplied JavaScriptKit runtime version. +* `JSSymbol` type is now supported for bridging [JavaScript `Symbol`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol). + +**Merged pull requests:** + +- Improve JSKit diagnostics for use-after-free of JSClosure ([#195](https://github.com/swiftwasm/JavaScriptKit/pull/195)) via [@kateinoigakukun](https://github.com/kateinoigakukun) +- Gracefully handle unavailable `JSBridgedClass` ([#190](https://github.com/swiftwasm/JavaScriptKit/pull/190)) via [@MaxDesiatov](https://github.com/MaxDesiatov) +- Supply JSKit runtime in SwiftPM resources ([#193](https://github.com/swiftwasm/JavaScriptKit/pull/193)) via [@MaxDesiatov](https://github.com/MaxDesiatov) +- Test with Node.js's WASI implementation ([#192](https://github.com/swiftwasm/JavaScriptKit/pull/192)) via [@kateinoigakukun](https://github.com/kateinoigakukun) +- Add support for BigInts and BigInt-based TypedArrays ([#184](https://github.com/swiftwasm/JavaScriptKit/pull/184)) via [@j-f1](https://github.com/j-f1) +- Update toolchain references to 5.6.0 in `README.md` ([#189](https://github.com/swiftwasm/JavaScriptKit/pull/189)) via [@MaxDesiatov](https://github.com/MaxDesiatov) +- Bump async from 2.6.3 to 2.6.4 in /Example ([#188](https://github.com/swiftwasm/JavaScriptKit/pull/188)) via [@dependabot[bot]](https://github.com/dependabot[bot]) +- Remove outdated `BigInt` support `FIXME` from `JSTypedArray` ([#187](https://github.com/swiftwasm/JavaScriptKit/pull/187)) via [@MaxDesiatov](https://github.com/MaxDesiatov) +- Cleanup & improvements to perf-tester ([#186](https://github.com/swiftwasm/JavaScriptKit/pull/186)) via [@j-f1](https://github.com/j-f1) +- Re-add support for Symbol objects via JSSymbol ([#183](https://github.com/swiftwasm/JavaScriptKit/pull/183)) via [@j-f1](https://github.com/j-f1) +- Fix JSValueDecoder ([#185](https://github.com/swiftwasm/JavaScriptKit/pull/185)) via [@j-f1](https://github.com/j-f1) +- Fix deprecation warning in `JSFunction.swift` ([#182](https://github.com/swiftwasm/JavaScriptKit/pull/182)) via [@MaxDesiatov](https://github.com/MaxDesiatov) + # 0.14.0 (8 April 2022) This is a breaking release that enables full support for SwiftWasm 5.6 and lays groundwork for future updates to [DOMKit](https://github.com/swiftwasm/DOMKit/). diff --git a/Example/package-lock.json b/Example/package-lock.json index 65a52a803..8d8358675 100644 --- a/Example/package-lock.json +++ b/Example/package-lock.json @@ -21,7 +21,7 @@ }, "..": { "name": "javascript-kit-swift", - "version": "0.14.0", + "version": "0.15.0", "license": "MIT", "devDependencies": { "@rollup/plugin-typescript": "^8.3.1", diff --git a/package-lock.json b/package-lock.json index 9d0372017..809b03030 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "javascript-kit-swift", - "version": "0.14.0", + "version": "0.15.0", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "javascript-kit-swift", - "version": "0.14.0", + "version": "0.15.0", "license": "MIT", "devDependencies": { "@rollup/plugin-typescript": "^8.3.1", diff --git a/package.json b/package.json index e24c39e27..90486f010 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "javascript-kit-swift", - "version": "0.14.0", + "version": "0.15.0", "description": "A runtime library of JavaScriptKit which is Swift framework to interact with JavaScript through WebAssembly.", "main": "Runtime/lib/index.js", "module": "Runtime/lib/index.mjs", From 3fb7ac156c9e856cafe6a6dd18091d3c2d454122 Mon Sep 17 00:00:00 2001 From: Max Desiatov Date: Tue, 17 May 2022 15:50:45 +0100 Subject: [PATCH 2/4] Apply suggestions from code review Co-authored-by: Jed Fox --- CHANGELOG.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a759853b0..48075cace 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,14 +1,14 @@ # 0.15.0 (17 May 2022) This is a major release that adds new features and fixes issues. Specifically: -* `BigInt` and `BigInt`-based `JSTypedArray` types are now supported. Now, when passing `Int64` function from Swift, -it will be mapped to `BigInt` on JavaScript side. -* `constructor` property on `JSBridgedClass` is now optional, which allows bridging JavaScript classes that aren't -available in every browser. +* `BigInt` and `BigInt`-based `JSTypedArray` types are now supported. Now, when passing `Int64` values from Swift, +they will be mapped to `BigInt` values on the JavaScript side. +* The `constructor` property on `JSBridgedClass` is now an Optional, which allows bridging JavaScript classes that aren't +available in every browser or environment. * JavaScriptKit runtime files are now supplied as SwiftPM resources. This allows us to resolve a long-standing issue in `carton` that could lead to a version mismatch between JavaScriptKit dependency in `Package.swift` or -`Package.resolved` and supplied JavaScriptKit runtime version. -* `JSSymbol` type is now supported for bridging [JavaScript `Symbol`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol). +`Package.resolved` and carton’s bundled JavaScriptKit runtime version. +* The `JSSymbol` type has been added, enabling support for [JavaScript `Symbol` values](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol), including accessing `Symbol`-keyed properties on objects. **Merged pull requests:** From 6d2d69660bb4175d588cba10cd5a46a7475a44ef Mon Sep 17 00:00:00 2001 From: Max Desiatov Date: Thu, 19 May 2022 14:15:06 +0100 Subject: [PATCH 3/4] Update CHANGELOG.md Co-authored-by: Yuta Saito --- CHANGELOG.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 48075cace..f97134e00 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,12 @@ in `carton` that could lead to a version mismatch between JavaScriptKit dependen `Package.resolved` and carton’s bundled JavaScriptKit runtime version. * The `JSSymbol` type has been added, enabling support for [JavaScript `Symbol` values](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol), including accessing `Symbol`-keyed properties on objects. +**Source breaking changes** + +`UInt64.jsValue` and `Int64.jsValue`, which are a part of `JavaScriptKit` module, has been moved into `JavaScriptBigIntSupport` module since their implementation has been changed to require [JS-BigInt-integration](https://github.com/WebAssembly/JS-BigInt-integration) to avoid implicit cast from 64-bit integer to JS `Number`. + +If you want to keep the behavior so far, please cast the 64-bit integer values to `Double`. + **Merged pull requests:** - Improve JSKit diagnostics for use-after-free of JSClosure ([#195](https://github.com/swiftwasm/JavaScriptKit/pull/195)) via [@kateinoigakukun](https://github.com/kateinoigakukun) From aec82755b83d954c0e0acb093b2bc339bf4913e2 Mon Sep 17 00:00:00 2001 From: Max Desiatov Date: Thu, 19 May 2022 14:16:42 +0100 Subject: [PATCH 4/4] Update CHANGELOG.md --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f97134e00..62f7fff55 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,7 +12,7 @@ in `carton` that could lead to a version mismatch between JavaScriptKit dependen **Source breaking changes** -`UInt64.jsValue` and `Int64.jsValue`, which are a part of `JavaScriptKit` module, has been moved into `JavaScriptBigIntSupport` module since their implementation has been changed to require [JS-BigInt-integration](https://github.com/WebAssembly/JS-BigInt-integration) to avoid implicit cast from 64-bit integer to JS `Number`. +`UInt64.jsValue` and `Int64.jsValue`, which are a part of `JavaScriptKit` module, have been moved into `JavaScriptBigIntSupport` module since their implementation changed to require [JS-BigInt-integration](https://github.com/WebAssembly/JS-BigInt-integration) to avoid implicit casts from 64-bit integer to JS number type. If you want to keep the behavior so far, please cast the 64-bit integer values to `Double`.