- In a new or existing project called
MyProject
(for example) add the .h, .m and .swift files to the/ios/
directory - Put the ReactNativeSwiftPromises file wherever you like
- Launch/compile your react native project. Note: whenever you change the native files you'll need to recompile with XCode
NOTE: if this example doesn't compile/work let me know. I just pasted random bits from a project without checking if it compiles. I'm using 9.2 with RN 0.55.2
it would be really cool if you add an example of how to handle delegates such as these
keeping in mind that
.catch
&.then
would need to be invoked by other functions.