blob: 6ed6da6ab8961368214495553e8d363c022fd53d [file] [log] [blame]
buildscript {
repositories {
mavenLocal()
mavenCentral()
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
apply plugin: 'kotlin-multiplatform'
repositories {
mavenLocal()
mavenCentral()
}
kotlin.targets.fromPreset(kotlin.presets.js, 'nodeJs')
dependencies {
nodeJsMainApi "org.jetbrains.kotlin:kotlin-stdlib-js:$kotlin_version"
}
compileKotlinNodeJs.kotlinOptions.outputFile = "${buildDir}/examplelib.js"
compileKotlinNodeJs.kotlinOptions.sourceMap = true
nodeJsJar {
from buildDir
include "**/*.js"
include "**/*.js.map"
}
nodeJsJar.dependsOn(compileKotlinNodeJs)