Skip to content

Commit 306de89

Browse files
BridgeJS: Remove JAVASCRIPTKIT_EXPERIMENTAL_BRIDGEJS feature gate
1 parent bc2c9a1 commit 306de89

File tree

6 files changed

+5
-10
lines changed

6 files changed

+5
-10
lines changed

Benchmarks/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ This directory contains performance benchmarks for JavaScriptKit.
77
Before running the benchmarks, you need to build the test suite:
88

99
```bash
10-
JAVASCRIPTKIT_EXPERIMENTAL_BRIDGEJS=1 swift package --swift-sdk $SWIFT_SDK_ID js -c release
10+
swift package --swift-sdk $SWIFT_SDK_ID js -c release
1111
```
1212

1313
## Running Benchmarks

Examples/ExportSwift/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ This example demonstrates how to export Swift functions to JavaScript.
55

66
1. Build the project:
77
```sh
8-
env JAVASCRIPTKIT_EXPERIMENTAL_BRIDGEJS=1 swift package --swift-sdk $SWIFT_SDK_ID js --use-cdn
8+
swift package --swift-sdk $SWIFT_SDK_ID js --use-cdn
99
```
1010

1111
2. Serve the files:

Examples/PlayBridgeJS/build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/bin/bash
22
set -euxo pipefail
3-
env JAVASCRIPTKIT_EXPERIMENTAL_BRIDGEJS=1 swift package --swift-sdk "${SWIFT_SDK_ID_wasm32_unknown_wasip1:-${SWIFT_SDK_ID:-wasm32-unknown-wasip1}}" \
3+
swift package --swift-sdk "${SWIFT_SDK_ID_wasm32_unknown_wasip1:-${SWIFT_SDK_ID:-wasm32-unknown-wasip1}}" \
44
plugin --allow-writing-to-package-directory \
55
js --use-cdn --output ./Bundle -c "${1:-debug}"

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ unittest:
1616
echo "SWIFT_SDK_ID is not set. Run 'swift sdk list' and pass a matching SDK, e.g. 'make unittest SWIFT_SDK_ID=<id>'."; \
1717
exit 2; \
1818
}
19-
env JAVASCRIPTKIT_EXPERIMENTAL_BRIDGEJS=1 swift package --swift-sdk "$(SWIFT_SDK_ID)" \
19+
swift package --swift-sdk "$(SWIFT_SDK_ID)" \
2020
$(TRACING_ARGS) \
2121
--disable-sandbox \
2222
js test --prelude ./Tests/prelude.mjs -Xnode --expose-gc

Plugins/BridgeJS/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# BridgeJS
22

33
> [!IMPORTANT]
4-
> This feature is still experimental, and the API may change frequently. Use at your own risk with `JAVASCRIPTKIT_EXPERIMENTAL_BRIDGEJS=1` environment variable.
4+
> This feature is still experimental, and the API may change frequently. Use at your own risk.
55
66
> [!NOTE]
77
> This documentation is intended for JavaScriptKit developers, not JavaScriptKit users. For user documentation, see [Exporting Swift to JavaScript](https://swiftpackageindex.com/swiftwasm/JavaScriptKit/documentation/javascriptkit/exporting-swift-to-javascript) and [Importing TypeScript into Swift](https://swiftpackageindex.com/swiftwasm/JavaScriptKit/documentation/javascriptkit/importing-typescript-into-swift).

Plugins/PackageToJS/Sources/PackageToJS.swift

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -589,11 +589,6 @@ struct PackagingPlanner {
589589
packageInputs.append(packageJsonTask)
590590

591591
if skeletons.count > 0 {
592-
if ProcessInfo.processInfo.environment["JAVASCRIPTKIT_EXPERIMENTAL_BRIDGEJS"] == nil {
593-
fatalError(
594-
"BridgeJS is still an experimental feature. Set the environment variable JAVASCRIPTKIT_EXPERIMENTAL_BRIDGEJS=1 to enable."
595-
)
596-
}
597592
let bridgeJs = outputDir.appending(path: "bridge-js.js")
598593
let bridgeDts = outputDir.appending(path: "bridge-js.d.ts")
599594
packageInputs.append(

0 commit comments

Comments
 (0)