Building for iOS is an incredibly valuable skill for any developer. In this course, you'll use Xcode and Swift to make iOS apps with adaptive user interfaces that work on multiple devices, explore iOS app architecture, and more.
Developing for iOS is a valuable and in-demand skill, but if you haven't developed in the Apple world before, it can be surprisingly different. In this course, iOS 11 Fundamentals, you'll quickly get up and running using Xcode 9 and Swift 4 to build great iOS apps and tap into the latest features in iOS 11. First, you'll see the tools and learn how to create iOS apps with adaptive user interfaces that work on multiple devices (including iPhone X). Then, you'll learn how to manage iOS projects and define the building blocks of your own iOS applications. Finally, you'll explore working with data-driven controls and understand navigation options. By the end of the course, you'll know current best practices, iOS architecture, and the most important ideas you need to feel comfortable bringing your developer skills into the iOS and Apple developer world.
Simon is a staff author at Pluralsight. With a 30-year background in programming and teaching, he obsesses on making complicated subjects accessible, memorable, and easier to learn. Since 2002, he's recorded dozens of popular and highly-rated training courses. His current focus is on iOS and computer science topics.
Course Overview Hi, this is Simon Allardice, and welcome to iOS 11 Fundamentals. Developing iOS apps is an incredibly valuable skill, but many software developers are surprised by just how different it can be to jump into the Apple developer world if it's not what you're used to. Now in this course we're going to explore not just the code, but the most important ideas, techniques, and skills that you will always need when doing any iOS development. We'll get comfortable with the most current and up-to-date tools, Xcode 9 and the Swift 4 programming language. We'll cover creating iOS projects, how to name them well, and we'll dive into the important ideas and architecture that make them work, what Apple are going to provide and what you need to provide. We'll build iOS user interfaces that can automatically adjust themselves to work on multiple devices, from the smallest iPhone to the largest iPad, and everything in between, including the latest iPhone X. And we'll build apps with data-driven controls, navigation controls and we'll explore common sticking points and how you get passed them. And they'll be a real focus on understanding the architecture, how to think about building iOS apps, so that by the end of this course you'll feel comfortable bringing all of your skills into the Apple developer world. This is iOS 11 Fundamentals at Pluralsight. Let's get started.
Building Single View Applications There are thousands of successful apps in the app store, where the entire app is presented within the boundaries of what you see on that very first screen. As examples, think of things like the Calculator app or the Voice Memo app in iOS itself, and when an iOS app has a singular focus, a single responsibility like this, it often doesn't need navigation. Now, some apps will need it, like the Mail app or the Settings app, they need the navigation bar at the top to allow us to drill down from screen to screen, understand where we are, and drill back up again. With other apps, we'll have buttons at the bottom to switch between different sections like in the iOS music app or the health application. And we'll be exploring all of these options in this course, but we're going to begin with apps that don't need navigation, that can do everything they need to do on a single screen, because we can use this to get clear on key iOS concepts and ideas before we start throwing in navigation and having multiple different sections to an app. And let me tell you, there is a word you're going to see and hear a lot going forward, the word view, and that's because we use and need the word view everywhere in iOS. We've already used the Single View App template in Xcode, we see the word view in our storyboard, and in our code, and we'll see that word by itself, but also in terms like subview, View Controller, Stack View, Scroll View, Table View, view hierarchy, so we want to be clear what this word view means in iOS. Not just conceptually, but practically, in our Swift code, and in our user interface, and in this module, we're going to go deeper into all four areas, into Swift, Xcode, iOS architecture, and patterns and practices.
Creating and Configuring iOS Tables On any day where you use an iPhone or an iPad for more than a few minutes, you will almost certainly end up in an app that uses a table view. It is the most common way to show a structured, scrollable list of items, and table views are a core competency for an iOS developer. Here we'll see how to add them to our applications, how to configure them and provide them with data. And in working with table views, we will naturally get into something I mentioned earlier in the course, using the programming technique of delegation to make our lives' easier. And to be clear, what we're about to cover doesn't only apply to table views, it's that learning how to work with your first data-driven iOS control is kind of like learning to drive, and a table view is like learning to drive in a standard car with a manual transmission. There are several things we need to do, and do in the right order, to make this go, but once you know how to do those things, you can immediately use the same techniques in a bunch of other places. Let me show you want I mean by that.
Creating iOS Apps with Multiple Screens When we're thinking about an application, and we know what we want to build is not going to fit on a single screen of content, we will split our application's user interface and logic across multiple screens. Now there's a technical aspect to this, what do we actually add to the Xcode project to keep together the right set of user interface controls and logic and data for each one, but beyond that, what's important here isn't just how do we add multiple screens to our app, it's also how do we navigate? How do we transition from one section of our app to another section and back again, in a way that will make sense to a user? But many of the choices we'll make here are less about technical limitations and more about the nature of our application. Do we have several screens because we're drilling down into a hierarchy of nested information, and we need to move back up again, or do we have several screens because our app does five completely different things and we just need to switch from one to the other. So in this module we're going to cover multiple screens or View Controllers, how to transition, or segue, between them, wrapping navigation around them, and we'll also see some sample project templates that can help us with this.
Using Auto Layout and Stack Views Any iOS app you write must be able to run on many different devices. IOS 11 is an operating system that runs on the iPhone 5S, on the iPhone 6 and 6S, but the regular and the Plus version, the iPhone SE, the 7s and 8s, the iPhone X with its notch, and various iPad Airs, iPad minis, iPad Pros, even the sixth-generation iPod Touch. So we have multiple different physical screen sizes and different resolutions, and it's not the same layout, only larger or smaller, the aspect ratio of height to width is completely different. And beyond that, our app could be asked to switch from portrait to landscape, and beyond that, the user may have changed the settings on their device to say they want a larger font, or even a smaller font when possible, and our apps should support that when displaying text, whether that's text in labels, or text on buttons, or text in table views. And beyond even that, we may want to localize our application to support different languages, have UI elements able to adjust to hold different amounts of text or support languages that use right to left orientation, not just left to right orientation. But what we certainly don't want to have to do is create a pixel-perfect user interface for each different device. We need a user interface that can automatically adjust itself for multiple devices and orientations. We need them to be flexible. The better word is adaptive. A user interface needs to adapt to different circumstances, and Auto Layout is the feature that will help help us do that. And it's not some additional option that we have to enable, it's already in place. We just need to know how to start using it.