tree: 6fc76cb0e31799daeb2bc42ba43c4e0e5cc16e5e [path history] [tgz]
  1. src/
  2. build.gradle.kts
  3. gradle.properties
  4. index.html
  5. README.md
kotlin-native/samples/html5Canvas/README.md

HTML5 Canvas

This sample shows how to use Kotlin/Native to build a WebAssembly application and how to call JavaScript functions from a Kotlin/Native code.

Note: If you build this sample not from the Kotlin/Native repository, you need to specify a path to a Kotlin/Native distribution. Add the following snippet in gradle.properties:

kotlin.native.home=<path-to-distribution>

The default distribution path is $HOME/.konan/kotlin-native-<macos|linux|windows>-<version>.

To build use ../gradlew assemble.

To run use ../gradlew runProgram.