Best iOS hacks from Twitter: November Edition

The development community was pretty active in November, so I found many excellent iOS Twitter tips for you.

Get ready to explore latest Xcode 9 features (and just for a moment forget about some bugs!), lots of tips on Unit Testing (which you’ve promised to start writing next year), handy LLDB details and some funny moments! Enjoy 280-symbol gems from the last month.

Twitter tip #1
This handy explanatory table will describe all “guts” that are hidden behind Pointer’s name:

Twitter tip #2
A “Golden Rule” to follow when working with Core Data/Realm and multiple threads. This way database maintenance won’t become a nightmare over time.

Twitter tip #3
A nice use-case for variable shadowing! You can use it to make sure you’re referring to the local mutable copy of an argument value instead of the original argument.

Twitter tip #4
Every journey starts with a single step. Even a unit-tests journey is achievable if you’ll follow these 3 simple rules:

Twitter tip #5
After John Sundell inspired us, you have started doing unit tests, right? 
And thanks to Arek, now you know that ⌃⌥⌘U shortcut can behave differently based on the cursor position:

Twitter tip #6
Xcode’s energy impact analyzer is really powerful. You can even estimate energy impact on iPhone X according to OLED power pattern. Not a pure tip, but good to know!

Twitter tip #7
Nice improvements in the latest Xcode 9. Now you can check system version in the runtime using `@available` keyword with Objective-C projects:

Twitter tip #8
Another great tip on the latest Xcode. Here is how to improve the UI performance by removing a single file.

Twitter tip #9
Stop updating constraints for animation when using AutoLayout. There is a better way:

Twitter tip #10
Have you ever wanted to use your fingerprint as your sudo password on Macbook Pro? Well now with this single line you can do that.

Twitter tip #11
Dictionary’s alt subscript at its best. The first version is much cleaner and also a bit faster.

Twitter tip #12
Embrace the full potential of LLDB’s e (e stands for expression) command and stop using po command all the time. This will dramatically improve your debugging experience.

Twitter tip #13
Have a hard time with LLDB expressions? With this command you can see the log output and find out what was wrong.

Twitter tip #14
Stick to this naming convention and the future you will appreciate it:

Twitter tip #15
That’s why you should avoid implicitly unwrapped optionals:

Twitter fun 🙃
And some very funny moments from the last month, just to make your working day a bit brighter:

As usual, many thanks to all the community for these hacks and gems! Let’s keep spreading the knowledge every day. The Christmas tips edition is coming soooon.

P.S.: Maybe you know, that I’m a startup founder and we’re working hard to push Flawless App forward. If you have some time to support our tool for visual quality check, please give us your honest feedback. The more feedback we get, the more we can improve Flawless App. Thanks :)