Created
July 25, 2019 18:36
-
-
Save SorenV/6ae0de00c9529f04e05ef4f17df80d2b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
val kotlinVersion = "1.3.41" | |
val kotlinxHtmlVersion = "0.6.12" | |
val kotlinExtensionsVersion = "1.0.1-pre.80-kotlin-1.3.41" | |
val reactVersion = "16.8.6-pre.80-kotlin-$kotlinVersion" | |
val reactDomVersion = "16.8.6-pre.80-kotlin-$kotlinVersion" | |
plugins { | |
val kotlinVersion = "1.3.41" | |
kotlin("js") version kotlinVersion | |
id("kotlin-dce-js") version kotlinVersion | |
} | |
repositories { | |
jcenter() | |
mavenCentral() | |
maven(url = "https://dl.bintray.com/kotlin/kotlin-eap") | |
maven(url = "https://dl.bintray.com/kotlin/kotlin-dev") | |
maven(url = "https://dl.bintray.com/kotlinx/kotlinx") | |
maven(url = "https://dl.bintray.com/kotlin/kotlin-js-wrappers") | |
} | |
kotlin { | |
target { | |
browser { | |
val main by compilations.getting { | |
kotlinOptions { | |
metaInfo = false | |
sourceMap = true | |
moduleKind = "umd" | |
sourceMapEmbedSources = "always" | |
} | |
} | |
} | |
sourceSets { | |
main { | |
dependencies { | |
implementation("org.jetbrains.kotlin:kotlin-stdlib-js:$kotlinVersion") | |
implementation("org.jetbrains.kotlinx:kotlinx-html-js:$kotlinxHtmlVersion") | |
implementation("org.jetbrains:kotlin-react:$reactVersion") | |
implementation("org.jetbrains:kotlin-extensions:$kotlinExtensionsVersion") | |
implementation("org.jetbrains:kotlin-react-dom:$reactDomVersion") | |
implementation(npm("react")) | |
implementation(npm("core-js")) | |
implementation(npm("react-dom")) | |
compileOnly(npm("babel-loader")) | |
compileOnly(npm("@babel/core")) | |
compileOnly(npm("uglifyjs-webpack-plugin")) | |
} | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment