Are you taking the challenge of developing an App for the Apple Watch? Are you nervous because you don’t have any working experience with iOS? Don’t worry here we will present you with a simple guideline divided into five basic steps.
We recommend you have a glance at the following steps that helps you to fulfill your first ever iWatch app development.
Step 1: Install
At the very beginning, you need an Xcode edition with the support of a Watch Kit. Currently the latest edition available Xcode 6.2 of beta 5 with WatchKit. You can download this edition from Member Center.
After installing Xcode, double tap on the Xcode 6.2 beta 5.dmg file to download.
Step 2: Create Project
Open Xcode file then click on ‘Create a new Xcode project’
Then choose ‘Single View Application’ to make a vacant project.
Fill up Organization Name, Product Name, and Organization Identifier. Select Objective-C or Swift for the devices and language you require. Choose the next option to go to the directory for selecting the project and finish.
Now you get a project and if you want to infuse some features to develop an Apple Watch. You need to add Apple Watch as an iOS app for a new target.
Step 3: Add Apple Watch Target
With the help of WatchKit Xcode, there you will find an ‘Apple Watch’ segment in the Targets.
You should select ‘File’ > ‘New’ > ‘Target’ for adding new target. There you will get the Apple Watch section where you should click and select the Watch App.
Thereafter, you will see a blank form of Glance and Notification options to check these boxes. Xcode will add those and if you ever forget to check them no worry because you can manually add them anytime.
Click the ‘Finish’ option and Congratulations! You have succeeded in your first iWatch app development.
Step 4: Create some cool stuff
Now you know you have a proper project with Watch App. You can see there are 2 directories that have added to the project WKExample WatchKit App and WKExample WatchKit Extension.
In the WKExample WatchKit App, you will get a storyboard there you can develop the Watch App.
You can write the Watch App from the classes of WKExample WatchKit Extension. Moreover, it enables you to make new classes and write the code files.
Over the Interface. storyboard, you can design the Watch App, and it looks similar to the files of the iOS Storyboard. From the Object Library, drag a Button and Label then put them to Interface Controller.
There is a slight difference between iOS and iWatch applications. You cannot find any auto layout option in WatchKit but you will have a Size properties option where you can set the height and width of the object. Select the label and then can manage with the values here.
Step 5: Finish and run
Now here you can see what cool stuff you have done. Run the target Watch App of the project. Here you can see the final edition of the project. If you feel it is not yet cool enough then you can download and copy the Bezel to the simulator screen.