0

I made a custom iOS Swift framework with some simple form validation methods and some tests. I open-sourced it to Github.

What if another developer uses my framework for their app but changes the method names? Could that potentially crash my app? I mean, one framework is shared between multiple apps, right?

ma11hew28
  • 121,420
  • 116
  • 450
  • 651

1 Answers1

0

If I understand what you're asking, only people with pull access will be able to change your framework.

If someone changes it, you then download the framework with the new changes and replace it within your app, yes it will break. Otherwise if they fork the project, or you never add the changed framework to your app, nothing will change.

The Framework you use in Xcode is a copy of the framework, it's not a reference to what exists on github.

GetSwifty
  • 7,568
  • 1
  • 29
  • 46
  • Imagine that I've installed on my iOS device two apps, each containing one copy of the same custom Swift framework. But, breaking changes have been made to the code of one of the framework copies. I've read that iOS (to decrease the memory footprint) loads only one copy of a framework into memory for all apps to share. So, if iOS loads the broken framework copy instead of the working one I ship with my app, won't my app crash? – ma11hew28 Mar 18 '16 at 22:49
  • I believe that's only true for system frameworks. E.G. frameworks installed by apple. http://stackoverflow.com/questions/15262427/do-ios-apps-share-frameworks – GetSwifty Mar 19 '16 at 16:03