Skip to content

Commit aaf39de

Browse files
committed
Fix sample to be compatible with example in playground
1 parent 873c1ff commit aaf39de

File tree

1 file changed

+9
-7
lines changed
  • cache-maker/src/main/resources

1 file changed

+9
-7
lines changed

cache-maker/src/main/resources/File.kt

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,24 @@
1+
import androidx.compose.ui.ExperimentalComposeUiApi
2+
import androidx.compose.ui.window.CanvasBasedWindow
13
import androidx.compose.animation.AnimatedVisibility
4+
import androidx.compose.foundation.Image
25
import androidx.compose.foundation.layout.Column
36
import androidx.compose.foundation.layout.fillMaxWidth
47
import androidx.compose.material.Button
58
import androidx.compose.material.MaterialTheme
69
import androidx.compose.material.Text
7-
import androidx.compose.runtime.*
10+
import androidx.compose.runtime.Composable
11+
import androidx.compose.runtime.getValue
12+
import androidx.compose.runtime.mutableStateOf
13+
import androidx.compose.runtime.remember
14+
import androidx.compose.runtime.setValue
815
import androidx.compose.ui.Alignment
9-
import androidx.compose.ui.ExperimentalComposeUiApi
1016
import androidx.compose.ui.Modifier
11-
import androidx.compose.ui.window.ComposeViewport
12-
import kotlinx.browser.document
1317

1418
//sampleStart
1519
@OptIn(ExperimentalComposeUiApi::class)
1620
fun main() {
17-
ComposeViewport(document.body!!) {
18-
App()
19-
}
21+
CanvasBasedWindow { App() }
2022
}
2123

2224
@Composable

0 commit comments

Comments
 (0)