Hello, I am trying to build an iOS app with this package https://github.com/bitwala/react-native-idnow using EAS on a managed workflow. It requires me to update the podfile, which I’m currently using a local plugin for it , but it also requires me to add a .h and .m files (taken from here) to the project (In Xcode I would be dragging those files to the project). I’m also able to create those files with the plugin but I think I’m missing the part where I add them to the build phases of the project.
Is this possible to do dynamically with EAS plugins?
It’s possible to modify build phases with mods.ios.xcodeproj, but the way I understand those instructions is that you only need to follow Additional required steps: section
manual section describes steps that would be necessary for old react-native versions that do not have auto-linking
Yes indeed, the only step that I’m missing is the * Add RNIdnow.handRNIdnow.m files to the ios project(see demo app) step.
I will look into this mods section. Thanks!
I’m also interested in this. I had a look yesterday in the usual places (expo/expo and expo/config-plugins repositories on GitHub) but didn’t find an example.
I haven’t yet worked out how to use mods directly as opposed to withProjectBuildGradle etc., but I imagine you should get access to the parsed file which you can then manipulate with the xcode npm module. The docs for that seem a bit lacking, though.
added the path to a local plugin on expo.plugins array in app.json
created a plugin similar to the withNotificationsIOS.ts plugin.
imported IOSConfig from @expo/config-plugins and checked the methods in IOSConfig.XcodeUtils. There are methods such as addBuildSourceFileToGroup or addFileToGroupAndLink that will update the project as if you did it with XCode.