plugins { id 'kotlin-multiplatform'// version '1.3.0-rc-57' id 'kotlinx-serialization' } repositories { maven { url = 'http://dl.bintray.com/kotlin/kotlin-eap' } mavenCentral() } kotlin { targets { fromPreset(presets.jvm, 'jvm') fromPreset(presets.js, 'js') // For ARM, preset should be changed to presets.iosArm32 or presets.iosArm64 // For Linux, preset should be changed to e.g. presets.linuxX64 // For MacOS, preset should be changed to e.g. presets.macosX64 //fromPreset(presets.iosX64, 'ios') } sourceSets { commonMain { dependencies { implementation "org.jetbrains.kotlin:kotlin-stdlib-common" implementation 'org.jetbrains.kotlin:kotlin-reflect' implementation "org.jetbrains.kotlinx:kotlinx-io:$kotlinx_io_version" implementation "org.jetbrains.kotlinx:kotlinx-serialization-runtime-common:$serialization_version" } } commonTest { dependencies { implementation 'org.jetbrains.kotlin:kotlin-test-common' implementation 'org.jetbrains.kotlin:kotlin-test-annotations-common' implementation "org.jetbrains.kotlinx:kotlinx-serialization-runtime-common:$serialization_version" } } jvmMain { dependencies { implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8" implementation "org.jetbrains.kotlinx:kotlinx-serialization-runtime:$serialization_version" } } jvmTest { dependencies { implementation 'org.jetbrains.kotlin:kotlin-test' implementation 'org.jetbrains.kotlin:kotlin-test-junit' } } jsMain { dependencies { implementation 'org.jetbrains.kotlin:kotlin-stdlib-js' implementation "org.jetbrains.kotlinx:kotlinx-serialization-runtime-js:$serialization_version" } } jsTest { dependencies { implementation 'org.jetbrains.kotlin:kotlin-test-js' implementation "org.jetbrains.kotlinx:kotlinx-serialization-runtime-js:$serialization_version" } } // iosMain { // } // iosTest { // } } }