@@ -14,17 +14,17 @@ To add Seskar to your project, you need to add the following configuration to yo
1414
1515``` kotlin
1616plugins {
17- kotlin(" multiplatform" ) version " 2.3.10"
18- id(" io.github.turansky.seskar" ) version " 4.32 .0"
17+ kotlin(" multiplatform" ) version " 2.3.10"
18+ id(" io.github.turansky.seskar" ) version " 4.34 .0"
1919}
2020```
2121
2222### Kotlin/JS requirements
2323
2424* Target -` es2015 `
25- * [ example] ( https://github.com/JetBrains/kotlin-wrappers/blob/fdc8fb9b8ac2b13ba151449e13977a0327e7e3df/examples/buildSrc/src/main/kotlin/kotlin-conventions.gradle.kts#L35 )
25+ * [ example] ( https://github.com/JetBrains/kotlin-wrappers/blob/fdc8fb9b8ac2b13ba151449e13977a0327e7e3df/examples/buildSrc/src/main/kotlin/kotlin-conventions.gradle.kts#L35 )
2626* Granularity - ` per-file `
27- * [ example] ( https://github.com/JetBrains/kotlin-wrappers/blob/fdc8fb9b8ac2b13ba151449e13977a0327e7e3df/examples/gradle.properties#L7 )
27+ * [ example] ( https://github.com/JetBrains/kotlin-wrappers/blob/fdc8fb9b8ac2b13ba151449e13977a0327e7e3df/examples/gradle.properties#L7 )
2828
2929## Lazy functions
3030
@@ -67,7 +67,7 @@ sourceSets {
6767// App.kt
6868suspend fun main () {
6969 console.log(" App start!" )
70-
70+
7171 val value = if (Random .nextDouble() > 0.5 ) {
7272 createCalculationWithHeavyLibrary()
7373 } else {
@@ -76,14 +76,16 @@ suspend fun main() {
7676
7777 console.log(" Value: $value " )
7878}
79+ ```
7980
81+ ``` kotlin
8082// createCalculationWithHeavyLibrary.kt
8183import js.lazy.Lazy
8284import js.lazy.LazyFunction
8385
8486/* *
8587 * Function will be located in separate JS chunk
86- */
88+ */
8789@Lazy
8890val createCalculationWithHeavyLibrary = LazyFunction <Int > {
8991 val calculator = HeavyCalculator ()
@@ -102,7 +104,9 @@ val Content = FC {
102104 MyHeavyComponent1 ()
103105 MyHeavyComponent2 ()
104106}
107+ ```
105108
109+ ``` kotlin
106110// App.kt
107111val App = FC {
108112 Header ()
@@ -349,16 +353,16 @@ import seskar.js.JsRawValue
349353" "
350354sealed external interface GraphItemType {
351355 companion object {
352- @JsRawValue ("1" )
356+ @JsRawValue ("1" )
353357 val NODE : GraphItemType
354358
355- @JsRawValue ("2" )
359+ @JsRawValue ("2" )
356360 val EDGE : GraphItemType
357361
358- @JsRawValue ("4" )
362+ @JsRawValue ("4" )
359363 val PORT : GraphItemType
360364
361- @JsRawValue ("8" )
365+ @JsRawValue ("8" )
362366 val LABEL : GraphItemType
363367 }
364368}
0 commit comments