IBInspectable allowed but not supported in WatchKit apps

Originator:brent
Number:rdar://19040593 Date Originated:19-Nov-2014 09:13 PM
Status:Open Resolved:
Product:Developer Tools Product Version:Xcode-Beta (6C86e)
Classification:Enhancement Reproducible:Always
 
Summary:
You can mark a WKInterfaceController property as @IBInspectable and set its value in the storyboard, and neither IB nor the Swift compiler complains. However, the property is not actually set when you run the app.

Steps to Reproduce:
1. Create a new watch app.
2. Add an @IBInspectable property to it.
3. Select the corresponding scene in the Storyboard.
4. Set the property, build, and run.

Expected Results:
Either there is no UI to set the property, or building produces a warning or error, or this actually works.

Actual Results:
The value in the nib file is ignored.

Notes:
I only tested with Swift, but I suspect Objective-C has the same issue.

I would love it if WatchKit actually supported IBInspectable; it would permit a small amount of the dynamism that’s missing because we cannot create NSObjects in WatchKit storyboards. However, if that isn’t practical, the feature should at least be disabled in some way to avoid misleading developers.

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!