What is this kotlin("...") method described in Kotlin's "Using Gradle" tutorial? They mention this syntax.
plugins {
kotlin("jvm") version "1.3.71"
}
I see it used in more places too, not just the plugin. For example, it can be used to get Kotlin dependencies.
dependencies {
implementation(kotlin("stdlib-jdk8"))
}
I have tried googling this but I'm having trouble finding results since Gradle uses a Kotlin DSL as well and the results for the two get mixed.
Running gradle init --dsl kotlin --type kotlin-library outputs the "normal" syntax (see below for snipped output) and I can't find documentation on this strange kotlin("...") piece about what it can and can't be used for. If I use the kotlin("...") approach as above it still works but I'm trying to figure out what it is and where it comes from.
plugins {
// Apply the Kotlin JVM plugin to add support for Kotlin.
id("org.jetbrains.kotlin.jvm") version "1.3.71"
// Apply the java-library plugin for API and implementation separation.
`java-library`
}
// ...
dependencies {
// Align versions of all Kotlin components
implementation(platform("org.jetbrains.kotlin:kotlin-bom"))
// Use the Kotlin JDK 8 standard library.
implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk8")
// Use the Kotlin test library.
testImplementation("org.jetbrains.kotlin:kotlin-test")
// Use the Kotlin JUnit integration.
testImplementation("org.jetbrains.kotlin:kotlin-test-junit")
}