Set `top` alignment in `MainView` to a fixed value for consistent rendering. Enabled source maps with embedded source content in the JS compiler for improved debugging. Adjusted build script directory paths and formatting for better clarity and maintainability.
49 lines
1.2 KiB
Kotlin
49 lines
1.2 KiB
Kotlin
@file:OptIn(ExperimentalKotlinGradlePluginApi::class, ExperimentalDistributionDsl::class)
|
|
|
|
import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi
|
|
import org.jetbrains.kotlin.gradle.targets.js.dsl.ExperimentalDistributionDsl
|
|
import org.jetbrains.kotlin.gradle.targets.js.webpack.KotlinWebpackOutput
|
|
|
|
buildscript {
|
|
apply(from = "../common.gradle.kts")
|
|
}
|
|
|
|
plugins {
|
|
kotlin("multiplatform")
|
|
}
|
|
|
|
kotlin {
|
|
js {
|
|
compilerOptions {
|
|
target.set("es2015")
|
|
}
|
|
binaries.executable()
|
|
|
|
browser {
|
|
commonWebpackConfig {
|
|
outputFileName = "vst-chip-worklet.js"
|
|
sourceMaps = true
|
|
}
|
|
|
|
webpackTask {
|
|
output.libraryTarget = KotlinWebpackOutput.Target.VAR
|
|
output.library = "vstChipWorklet"
|
|
}
|
|
|
|
distribution {
|
|
outputDirectory.set(File("$projectDir/../web2/"))
|
|
}
|
|
}
|
|
}
|
|
|
|
sourceSets {
|
|
val commonMain by getting {
|
|
dependencies {
|
|
implementation("nl.astraeus:vst-worklet-base:1.0.1")
|
|
implementation("nl.astraeus:midi-arrays:0.3.6")
|
|
}
|
|
}
|
|
val jsMain by getting
|
|
}
|
|
}
|