Shabinder Singh
03/12/2021, 11:58 AMput(key="data",*ArrayBuffer)*
but put only accepts JsonElement , so how to do this? as JS Function expects an ArrayBuffer there...
Any Help is Appreciated!Marc Knaup
03/12/2021, 3:18 PMMarc Knaup
03/12/2021, 3:19 PMJsonObject
is for kotlinx-serialization.
Do you mean a plain JS object with jsObject
?Shabinder Singh
03/12/2021, 3:19 PMShabinder Singh
03/12/2021, 3:20 PMMarc Knaup
03/12/2021, 3:23 PMbuildJsonObject
is not meant for JavaScript objects.
You can either define an external interface
for your expected type or use js { … }
from package org.jetbrains:kotlin-extensions:1.0.1-pre.148-kotlin-1.4.30
.
js {
this["type"] = 3
// ...
}
Shabinder Singh
03/12/2021, 3:24 PMShabinder Singh
03/12/2021, 3:24 PMMarc Knaup
03/12/2021, 3:25 PMMarc Knaup
03/12/2021, 3:25 PMJsonPrimitive
Marc Knaup
03/12/2021, 3:25 PMMarc Knaup
03/12/2021, 3:25 PM3
and "Cover Art"
Marc Knaup
03/12/2021, 3:25 PMjs
instead of jsObject<dynamic>
Shabinder Singh
03/12/2021, 3:25 PM