JSEval

expect object JSEval
actual object JSEval
actual object JSEval
actual object JSEval

Properties

Link copied to clipboard
expect val available: Boolean

Determines if JSEval is available. Available on the JS target. Not available on the other targets for now.

actual const val available: Boolean = false
actual const val available: Boolean = true
actual const val available: Boolean = false
Link copied to clipboard
expect val globalThis: Any?

Returns a reference to JavaScript globalThis, window or self. Null if available=false

actual val globalThis: Any?
actual val globalThis: Any?
actual val globalThis: Any?

Functions

Link copied to clipboard
fun JSEval.expr(expr: String, vararg params: Pair<String, Any?>): Any?

Executes a javascript expr expressions and return the result.

Link copied to clipboard
expect operator fun invoke(code: String, params: Map<String, Any?>): Any?

Executes a fragment of code in JavaScript when available is true.

actual operator fun invoke(code: String, params: Map<String, Any?>): Any?
actual operator fun invoke(code: String, params: Map<String, Any?>): Any?
actual operator fun invoke(code: String, params: Map<String, Any?>): Any?
Link copied to clipboard
operator fun JSEval.invoke(code: String, vararg params: Pair<String, Any?>): Any?