Skip to content

Uncaught (in promise) , when using this dependency in webMain for kotlin/js #21

@TheReprator

Description

@TheReprator

[webpack-dev-server] Server started: Hot Module Replacement enabled, Live Reloading enabled, Progress disabled, Overlay enabled.
log.js:39 [HMR] Waiting for update signal from WDS...
IrLinkageError.kt:11 Uncaught (in promise)
IrLinkageError
cause
:
undefined
message
:
"Function 'addEventListener' can not be called: No function found for symbol 'org.w3c.dom.events/EventTarget.addEventListener|addEventListener(kotlin.String;kotlin.Function1<org.w3c.dom.events.Event,kotlin.Unit>?;){}[0]'"
name
:
"IrLinkageError"
stack
:
"IrLinkageError: Function 'addEventListener' can not be called: No function found for symbol 'org.w3c.dom.events/EventTarget.addEventListener|addEventListener(kotlin.String;kotlin.Function1<org.w3c.dom.events.Event,kotlin.Unit>?;){}[0]'\n at throwIrLinkageError (webpack-internal:///./kotlin/kotlin-kotlin-stdlib.mjs:1341:9)\n at EventTargetListener.addDisposableEvent_m8gfbo_k$ (webpack-internal:///./kotlin/compose-multiplatform-core-compose-ui-ui.mjs:59105:94)\n at initEvents (webpack-internal:///./kotlin/compose-multiplatform-core-compose-ui-ui.mjs:58859:17)\n at ComposeWindow$platformContext$1$dragAndDropManager$1.WebDragAndDropManager (webpack-internal:///./kotlin/compose-multiplatform-core-compose-ui-ui.mjs:58960:3)\n at new ComposeWindow$platformContext$1$dragAndDropManager$1 (webpack-internal:///./kotlin/compose-multiplatform-core-compose-ui-ui.mjs:60695:25)\n at new ComposeWindow$platformContext$1 (webpack-internal:///./kotlin/compose-multiplatform-core-compose-ui-ui.mjs:61177:30)\n at new ComposeWindow (webpack-internal:///./kotlin/compose-multiplatform-core-compose-ui-ui.mjs:61667:29)\n at CanvasBasedWindow (webpack-internal:///./kotlin/compose-multiplatform-core-compose-ui-ui.mjs:60599:3)\n at main$lambda (webpack-internal:///./kotlin/sample.mjs:1000:111)"
[[Prototype]]
:
Error_0
constructor
:
ƒ IrLinkageError(message)
[[Prototype]]
:
Error
constructor
:
ƒ Error_0()
[[Prototype]]
:
Object

I am getting the above error when using this dependency in webMain for kotlin/js, for kotlin/wasm it is working fine, for repo: https://github.com/TheReprator/VideoWeb-KMP

Regards,
Vikram Singh

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions