Asset Catalogs in resource bundles

前端 未结 3 1956
逝去的感伤
逝去的感伤 2021-02-02 11:13

I have a separate bundle of resources that ship with my framework. I want to put and use an asset catalog in that bundle. However UIImage imageNamed: says it uses the current ap

3条回答
  •  醉梦人生
    2021-02-02 12:15

    As per Apple developer:

    Unfortunately it is not possible to load images from any car file aside from the one that Xcode compiles into your main bundle, as +imageNamed: does not accept a bundle parameter, which is what is needed to do so (and even then it would only be able to open a single asset catalog in a single bundle).

    Here is the link:

    https://devforums.apple.com/message/968859#968859

提交回复
热议问题