Skip to content

Example docs error in function declaration #5

@jhoughjr

Description

@jhoughjr

this function def in the example:
func fetch(_ url: String) -> JSPromise {
JSPromise(jsFetch(url).object!)!
}

should be

func fetch(_ url: String) -> JSPromise<JSObject, JSError> {
JSPromise(jsFetch(url).object!)!
}

Xcode will fix is as <Any,Any> which does not help.

Metadata

Metadata

Assignees

Labels

questionFurther information is requested

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions