Generate JS module kind type
^KT-27301 In Progress
This commit is contained in:
+18
@@ -0,0 +1,18 @@
|
||||
// DO NOT EDIT MANUALLY!
|
||||
// Generated by org/jetbrains/kotlin/generators/arguments/GenerateGradleOptions.kt
|
||||
package org.jetbrains.kotlin.gradle.dsl
|
||||
|
||||
@Suppress("DEPRECATION")
|
||||
enum class JsModuleKind (val kind: String) {
|
||||
MODULE_AMD("amd"),
|
||||
MODULE_PLAIN("plain"),
|
||||
MODULE_ES("es"),
|
||||
MODULE_COMMONJS("commonjs"),
|
||||
MODULE_UMD("umd");
|
||||
|
||||
companion object {
|
||||
fun fromKind(kind: String): JsModuleKind =
|
||||
JsModuleKind.values().firstOrNull { it.kind == kind }
|
||||
?: throw IllegalArgumentException("Unknown JS module kind: $kind")
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user