Antonios Barotsis
06/24/2020, 8:53 PMclient.on(('ready'), msg => { // do stuff here })
How can I define this event in my external class and how do I then use it?andylamax
06/24/2020, 10:21 PMaraqnid
06/25/2020, 9:24 AMon
function to the external class
definitions like so:
external class Client {
fun on(eventType: String, callback: (Message) -> Unit)
}
araqnid
06/25/2020, 9:25 AMMessage
interface too, or just pass dynamic
to the callbackAntonios Barotsis
06/25/2020, 6:45 PM