Take the 2-minute tour ×

I've been told that it's best practice to do so. I know the Facebook iOS SDK does this (look inside the FBDialog.bundle file). There are a few SO questions about how to create them as well. Apple also has a Bundle Programming Guide.

But in a nutshell (and localization aside), are there significant pros of storing image resources inside a .bundle file?

EDIT: I know that the .app product is a bundle itself. That is not my question. The question is whether to store the image resources inside the default "Resources" group or to store them inside a "Resource.bundle" file, like the Facebook iOS SDK does.

share|improve this question
add comment

2 Answers

up vote 2 down vote accepted

It just adds another layer of organization to your application bundle, making it more comprehensive. The only strict advantage I could see for using bundles in this manner would be to avoid potential file conflicts when using lots of 3rd party code in a same project.

share|improve this answer
add comment

Bundles provide a standardized structure for organizing resources. On iOS it's not like you have a wide range of options with respect to where you store resources.

share|improve this answer
So are you saying bundles are kind of overkill on iOS? –  samvermette Apr 25 '11 at 2:44
I think the point is that on iOS, you don't have much choice other than to store your images in your app's bundle. –  Caleb Apr 25 '11 at 3:09
You have a small degree of choice where in the bundle you place resource in iOS, but it's best to follow conventions to make your life easier. –  John Percival Hackworth Apr 25 '11 at 3:13
Maybe I wasn't clear enough. Updated the original question. –  samvermette Apr 25 '11 at 5:50
I'd store resources inside the bundle, which would allow for more flexibility in naming. Additionally, you can then treat the resources as a single unit which may simplify application provisioning. –  John Percival Hackworth Apr 25 '11 at 21:22
add comment

Your Answer


