Fix unconditional warning in JS compilation with sourceMap disabled.
This commit is contained in:
+1
-1
@@ -51,7 +51,7 @@ open class DefaultValues(val defaultValue: String, val possibleValues: List<Stri
|
||||
)
|
||||
|
||||
object JsSourceMapContentModes : DefaultValues(
|
||||
"\"${K2JsArgumentConstants.SOURCE_MAP_SOURCE_CONTENT_INLINING}\"",
|
||||
"null",
|
||||
listOf(
|
||||
K2JsArgumentConstants.SOURCE_MAP_SOURCE_CONTENT_NEVER,
|
||||
K2JsArgumentConstants.SOURCE_MAP_SOURCE_CONTENT_ALWAYS,
|
||||
|
||||
+2
-2
@@ -51,9 +51,9 @@ interface KotlinJsOptions : org.jetbrains.kotlin.gradle.dsl.KotlinCommonOptions
|
||||
/**
|
||||
* Embed source files into source map
|
||||
* Possible values: "never", "always", "inlining"
|
||||
* Default value: "inlining"
|
||||
* Default value: null
|
||||
*/
|
||||
var sourceMapEmbedSources: kotlin.String
|
||||
var sourceMapEmbedSources: kotlin.String?
|
||||
|
||||
/**
|
||||
* Prefix for paths in a source map
|
||||
|
||||
+4
-4
@@ -64,9 +64,9 @@ internal abstract class KotlinJsOptionsBase : org.jetbrains.kotlin.gradle.dsl.Ko
|
||||
get() = sourceMapField ?: false
|
||||
set(value) { sourceMapField = value }
|
||||
|
||||
private var sourceMapEmbedSourcesField: kotlin.String? = null
|
||||
override var sourceMapEmbedSources: kotlin.String
|
||||
get() = sourceMapEmbedSourcesField ?: "inlining"
|
||||
private var sourceMapEmbedSourcesField: kotlin.String?? = null
|
||||
override var sourceMapEmbedSources: kotlin.String?
|
||||
get() = sourceMapEmbedSourcesField ?: null
|
||||
set(value) { sourceMapEmbedSourcesField = value }
|
||||
|
||||
private var sourceMapPrefixField: kotlin.String?? = null
|
||||
@@ -117,7 +117,7 @@ internal fun org.jetbrains.kotlin.cli.common.arguments.K2JSCompilerArguments.fil
|
||||
noStdlib = true
|
||||
outputFile = null
|
||||
sourceMap = false
|
||||
sourceMapEmbedSources = "inlining"
|
||||
sourceMapEmbedSources = null
|
||||
sourceMapPrefix = null
|
||||
target = "v5"
|
||||
typedArrays = true
|
||||
|
||||
Reference in New Issue
Block a user