@wasm-tool/kotlin-loader

0.0.1 • Public • Published

@wasm-tool/kotlin-loader

Webpack loader for Kotlin

Installation

yarn add --dev @wasm-tool/kotlin-loader

Kotlin-native

We expect kotlin-native to be in your $PATH. To install check here

Usage

Add the loader and plugin in your webpack.config.js here:

module.exports = {
  // ...

  module: {
    rules: [
      {
        test: /Main.kt$/,
        loader: "@wasm-tool/kotlin-loader"
      }
    ]
  }, 
 // ...

  plugins: [
    new HtmlWebpackPlugin({
      template: 'index.html'
    }),
  ]
  // ...

};

Add this script to the index.html template

    <script wasm="program.wasm" src="program.wasm.js"></script>

Package Sidebar

Install

npm i @wasm-tool/kotlin-loader

Weekly Downloads

0

Version

0.0.1

License

MIT

Unpacked Size

3.61 kB

Total Files

4

Last publish

Collaborators

  • xtuc
  • sendilkumarn