Contents

hasProperty(_:)

Returns a Boolean value indicating whether the JavaScript value has a defined property with the specified name.

Declaration

func hasProperty(_ property: Any!) -> Bool
func hasProperty(_ property: String!) -> Bool

Parameters

  • property:

    The name of a property to query for in the JavaScript object value.

Return Value

true if the JavaScript object has a defined property by that name; otherwise, false.

See Also

Working with Container Values