Hi i'm working on project that have a table view with 10 controllers every controller have 3 subviews so i'll have more than 20 xib files. Could this be a problem when i submit my application at the app store. I wonder if there any limit for xib files ?
I can't forsee any reason why this would be a problem :)
You can give Apple a buzz if you want to check, maybe they can offer further advice.
http://developer.apple.com/contact/
Related
I am porting app code from another language and tool that already fully manages all logic for switching views.
The app will probably have about 10 unique scenes for now, but most likely just grow and grow over time :)
It appears the default now is to mash it all together in one big storyboard and code file and use builtin mechanism for swiching scenes.
As I am new to iOS/Swift/Xcode I am not sure what long-term feasibility is of these solutions:
Create unique storyboatd for each scene containing only one scene and switch manually
Create a nib? single scene for each scene and switch manually
Put everything together in one big storyboard and swich manually
My worries about putting everything together are at this point these:
App startup time
Xcode slugginish if it has to show 10+ scenes at the same time in the storyboard
What apple recommends is to use Storyboard, and simply switch between Views using segues just ctrl+Drag between views to create a segue and then call programmatically.
apple developer reference: Using segues
Nothing is sluggish you can use as many views per storyboard as you want. if there is like 25 views, xcode maybe become slow somehow.
Enjoy
It's kind of subjective, but:
App startup time
This is a non-issue. Storyboards are compiled down to XIBs so they're about the same as using NIBs performance-wise. And NIBs are plenty fast enough for most use cases.
Xcode slugginish if it has to show 10+ scenes at the same time in the storyboard
Not really. My Macbook is six years old and I have Storyboards with far more than ten screens. I find screen real-estate to be a far bigger issue than performance. With Xcode 7 you can also use multiple Storboards and link them together.
I am developing iOS app. I have more number of view controller in the storyboard. When i build the app for first time it takes longer time for loading (nearly 30 mins). After the first build it takes lesser time to build the app. and also if i made any changes in the storyboard then the app takes longer time to build the app(nearly 30 mins). My app size is 33 MB. I can’t figure it out where the problem arise . I think the problem is in the storyboard that i am using more number of view controller in the storyboard.
It sounds like you have put too many viewcontrollers in your storyboard. If the storyboard isnt touched after a build, it wont have to recompile a lot of things to do with it again. If it is touched it will have to recompile the whole thing. If you separate out sections to different storyboards you shouldnt feel these effects as much.
A first time build will always be the longest though as it will be compiling from scratch and wont be able to reuse already compiled sections of the program
Fonix is right. You need to bifurcate your storyboard, or maybe divide-into-multiple even. Editing anything on the storyboards forces it to recompile it to run.
Follow the best practices for storyboards mentioned here.
I think Fonix is right. If your app still takes longtime to build. There maybe something wrong on your computer. I meant the same problem with you. And try many methods, but it does not work. Finally I Found my computer`s disk had bad tracks
I started a project using the Storyboard in Xcode 6 and now I think I would like to use XIB files. Are there any risks associated with moving from Storyboard to XIB? I thought I read somewhere that Xcode 6 would prefer developers to use the Storyboard, is this true? Are there benefits of using the Storyboard over XIB files? I feel like you have more control when using XIB files. Is there something I'm missing? Am I able to convert fairly easily or would it make more sense to start my project over?
I'm an Android developer moving into iOS, so please forgive my lack of knowledge on the subject.
UPDATE
I am more interested in knowing if there are any risks or problems in switching from Storyboard to XIB mid project. Currently, I'm using Storyboard, but I am thinking of switching some parts to XIB. Will this cause any problems with my project? Is there anything I need to be aware of in doing this?
Code, storyboard and xibs are all different ways of creating views and layouts.
There is no rule that says you can only use one of them in a project.
In most of my projects I use a combination of all three.
Storyboards give a quick and easy way to create "flow" in the app. I tend to use one storyboard per "workflow" inside the app.
Xibs I tend to use for views that are common in multiple places within the app. In a storyboard I'd have to define them multiple times. Using xibs is a bit like refactoring interface builder files.
I then fall back to using code when necessary. Sometimes it isn't possible to do what I want with interface builder.
To say that you are only going to use xibs is purely denying yourself access to the other tools. Learn when to use each and how to use them together.
There are some things like container views and embed segues that only work with Storyboards.
For the most part, though, it's a question of personal taste.
Apple does seem to be moving in the direction of Storyboards, so as a new developer you may want to put your efforts into Storyboards.
There are a lot of articles on the internet that discuss this topic, example: http://www.toptal.com/ios/ios-user-interfaces-storyboards-vs-nibs-vs-custom-code
I would take a look at the answers to this question for some great info.
Here's a quick summary:
Storyboards have some great features such as letting you create segues between views, and design table view cells in-place.
The biggest downside to storyboards is working a project with multiple developers. Dealing with merge conflicts can be a big headache.
I have a view controller which contains a ScrollView and an array of views on that. When i rotate the device a strange situation happens with the frames of my view. I googled and Stackoverflow'd, i need to use two different .xib files but i have no idea about how to do. Can any one share some opinion-or link to tutorial please?
My app is Web-Service application and the information comes from a web server. I tried to create two different .xib files and display them differently but it is too much coplicated(or comes so to me). Please, just a link or an idea wwill be great helper
I've been trying to complete some basic tutorials to familiarize myself with UIViews and ViewControllers, but some tutorials I see ask me to select an "app name App Delegate" icon in the dock (just left of the Interface Builder panel). I'm seeing the icons for Placeholders: "File's Owner", "File's Responder" and icons for the Objects I've added to my view, but no icon for an App Delegate.
This is using an iOS Empty Application and not any other template when creating a new project and I'm basically trying to connect my App Delegate's rootViewController outlet to a view Controller in a nib file.
Has this icon been removed from XCode 4.2? Is it somewhere else or can be accessed in a different way? I'm guessing a lot of my confusion is because I'm referencing tutorials that came before XCode 4.2 and the new iOS 5 SDK. I'm really new to XCode and iOS in general and the lack of up to date tutorials is not helping my confusion. Any help would be greatly appreciated!
The default Xcode 4.2 templates no longer have the app delegate created by the xib. Instead, the class name is passed into UIApplicationMain so that can instantiate it. This change was made as part of Storyboard support, as I understand it.
I'm almost positive that I've had the same problem, but I figured out that for whatever reason, it would only accept the icon in png format. Try that and see if it works. If this answer is completely off topic, blame that on my lack of sleep for the past 36 hours.