I ran into a lot of trouble adding OneSignal notification to the IOS side of my detached project, so i thought I’d share.
Not sure i recommend this, cause it a bit hacky… usually when you are having to go through all this trouble your best choice it to move to another repo…
Here is how I made it work:
1.- npm instal and link. (link not cocoa, even though it’s against expo recommendations)
2.- Follow installation steps from the repo
4.- Let it run (it’s going to fail)
5.- An RCTConvert file is going to complain that its missing Yoga. Locate the folder containing RCTConvert and keep it in an open finder window.
6.- In native_modules, or in react, look the Yoga.h file, it lives in a Yoga folder containing 5 other support files. copy it.
7.- Paste it where RCT convert lives.
8.- Run it, it’s still going to fail. missing some files that it wants to import.
9.- Look for the issue, remove React/ from the import line code. run it again. (will fail again)
10.- It’s going to be the same issue, in a different import, so do the same.
11.- And again… be patient, it will happen 5-6 times. After that, it should build, link… work.
The Android install is a lot better.
I hope that helps.