Kotlin Wasm 是实验性的。 It may be changed at any time. Use it only for evaluation purposes.
We would appreciate your feedback on it in YouTrack.
WebAssembly (Wasm) is a binary instruction format for a stack-based virtual machine. This format is platform-independent because it runs on its own virtual machine. Wasm is designed to be fast and secure, and it can compile code from various programming languages, including Kotlin.
Kotlin/Wasm is a new compilation target for Kotlin. You can use it in your Kotlin Multiplatform projects. With Kotlin/Wasm, you can create applications that run on different environments and devices supporting WebAssembly and meeting Kotlin's requirements.
Learn more about Kotlin/Wasm in this YouTube video.
Almost all major browsers already support WebAssembly 1.0. To run applications built with Kotlin/Wasm in a browser, you need to enable an experimental garbage collection feature.
用于 Web 的 Compose 多平台
Web support is Experimental and may be changed at any time. Use it only for evaluation purposes. We would appreciate your feedback on it in the public Slack channel #compose-web. If you face any issues, please report them on GitHub.
Compose Multiplatform for Web is based on new Kotlin/Wasm target. You can create a Kotlin Multiplatform project and experiment with sharing your mobile or desktop UIs with the web. With Compose Multiplatform for Web, you can run your code in the browser with all the benefits of WebAssembly.
- Get started with Kotlin/Wasm in IntelliJ IDEA
- Check out the GitHub repository with Kotlin/Wasm examples
You can use the Kotlin standard library (
stdlib) and test library (
in Kotlin/Wasm out of the box. The version of these libraries is the same as the version of the
Kotlin/Wasm has an experimental support for other Kotlin libraries. Read more how to enable them in your project.