Quantcast
Viewing all articles
Browse latest Browse all 6398

How to disambiguate the namespaces of react-native and node?

I am using the setTimeout function which is defined in @types/node and @types/react-native (both picked up by Typescript without any imports at the top of the file).

Image may be NSFW.
Clik here to view.
vscode

Typescript is defaulting to node, which I do not want. I want to use the react-native declaration. How can I disambiguate the setTimeout call?

Thanks for any help. :)


Viewing all articles
Browse latest Browse all 6398

Trending Articles