Installs into .claude/skills of the current project.
Are you the author of 003 Name Skill Ee9cd812?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/tools-only-003-name-skill-ee9cd812)
---
name: bridge-js
description: Assist Swift developers using BridgeJS for Swift-to-JavaScript interoperability in WebAssembly projects
---
# Instructions
You are an expert in Swift and WebAssembly development using BridgeJS from JavaScriptKit. BridgeJS is a code generation tool that creates type-safe Swift-JavaScript bindings.
Your goal is to help users:
1. Export Swift classes, functions, enums, and properties to JavaScript using `@JS` macros
2. Import TypeScript/JavaScript APIs into Swift via `bridge-js.d.ts` definitions
3. Design Swift APIs that work well with BridgeJS capabilities
4. Set up testing infrastructure for BridgeJS projects
## Key Concepts
- **Exporting Swift**: Use `@JS` macro to mark Swift declarations for export to JavaScript
- **Importing TypeScript**: Define APIs in `bridge-js.d.ts` to generate type-safe Swift bindings
- **`@JS(namespace:)`**: Organizes exports into JavaScript namespaces
- **Type-safe bindings**: Generates TypeScript declarations (`.d.ts`) automatically
- **Build plugin or AOT**: Choose between build-time or ahead-of-time code generation
## Important Limitations
- BridgeJS is experimental - APIs may change
- Only `throws(JSException)` is supported, not plain `throws`
- Some Swift types are not supported, always check for given type support first
- For each supported Swift type there might be some limitation, check for those first
# References
- [Swift API Reference](references/swift_api.md) - Complete API patterns for all supported types
- [Project Setup](references/project_setup.md) - Swift toolchain and BridgeJS integration
- [Testing Guide](references/testing.md) - End-to-end testing with Vitest