Swift version: 5.2
View debugging lets you visualize exactly how your app is drawing to the screen by exploding your UI into 3D. So, if you're sure you added a button but you just can't see it, view debugging is for you: you can spin your interface around inside Xcode, and you'll probably find your button lurking behind another view because of a bug.
To activate view debugging, first you need to be using iOS 8.0, either on a device or the simulator. Run your app, and browse to the view controller you want to inspect. Now go to Xcode and look just below the main text editor, where the row of debugging buttons live: you want to click the button that has three rectangles in, just to the left of the location arrow.
When you use view debugging your app is paused, so make sure and tell Xcode to continue execution when you're done by pressing Cmd+Ctrl+Y.
SPONSORED ViRE offers discoverable way of working with regex. It provides really readable regex experience, code complete & cheat sheet, unit tests, powerful replace system, step-by-step search & replace, regex visual scheme, regex history & playground. ViRE is available on Mac & iPad.
Available from iOS 8.0 – see Hacking with Swift tutorial 18
This is part of the Swift Knowledge Base, a free, searchable collection of solutions for common iOS questions.
Link copied to your pasteboard.