then(success:failure:)
Schedules the success
closure to be invoked on successful completion of self
.
- iOS
- 13.0+
- macOS
- 10.15+
- tvOS
- 13.0+
- watchOS
- 6.0+
@discardableResult func then(success: sending @escaping (sending JSValue) async throws -> ConvertibleToJSValue, failure: sending @escaping (sending JSValue) async throws -> ConvertibleToJSValue) -> JSPromise