File tree Expand file tree Collapse file tree 4 files changed +7
-13
lines changed Expand file tree Collapse file tree 4 files changed +7
-13
lines changed Original file line number Diff line number Diff line change 11kotlin.code.style =official
22kotlin.js.compiler =ir
3- kotlin.incremental =true
4- kotlin.incremental.js =true
5- kotlin.incremental.js.ir =true
6- kotlin.incremental.js.klib =true
Original file line number Diff line number Diff line change 1- import org.w3c.dom .HTMLFormElement
1+ import web.html .HTMLFormElement
22import react.*
3- import org.w3c.dom .HTMLInputElement
3+ import web.html .HTMLInputElement
44import react.dom.events.ChangeEventHandler
55import react.dom.events.FormEventHandler
6- import react.dom .html.InputType
6+ import web .html.InputType
77import react.dom.html.ReactHTML.form
88import react.dom.html.ReactHTML.input
99
Original file line number Diff line number Diff line change 1- import kotlinx.browser .document
1+ import web.dom .document
22import react.create
33import react.dom.client.createRoot
44
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ val connectionString: ConnectionString? = System.getenv("MONGODB_URI")?.let {
2020}
2121
2222val client = if (connectionString != null ) KMongo .createClient(connectionString).coroutine else KMongo .createClient().coroutine
23- val database = client.getDatabase(connectionString?.database ? : " test " )
23+ val database = client.getDatabase(connectionString?.database ? : " shoppingList " )
2424val collection = database.getCollection<ShoppingListItem >()
2525
2626fun main () {
@@ -47,9 +47,7 @@ fun main() {
4747 ContentType .Text .Html
4848 )
4949 }
50- static(" /" ) {
51- resources(" " )
52- }
50+ staticResources(" /" , " static" )
5351 route(ShoppingListItem .path) {
5452 get {
5553 call.respond(collection.find().toList())
@@ -66,4 +64,4 @@ fun main() {
6664 }
6765 }
6866 }.start(wait = true )
69- }
67+ }
You can’t perform that action at this time.
0 commit comments