call(withArguments:)
Invokes the value as a JavaScript function.
Declaration
func call(withArguments arguments: [Any]!) -> JSValue!Parameters
Return Value
The result of calling the value as a function, or nil if the value cannot be treated as a JavaScript function.
Discussion
In JavaScript, if a function does not explicitly return a value, it implicitly returns the value undefined—use the isUndefined property to test for this result.