Blog

Welcome and let’s explore together

Instruments: adding context to Deferred recordings

Instruments templates like Allocations or Leaks run in Deferred recording mode by default. And it makes sense, because it would probably be too hard for Instruments to render results in realtime. But it creates this weird disconnect where you look at the graph later and think: “okay… but what was my app actually doing here?” What did help — using signposts / Points of Interest not…

Why Choose TDD Over Writing Tests After the Code?

I know that there are many different reasons why a developer might pick one approach over another when tackling any given question. But here’s my line of thinking regarding tests. There is value in writing tests after the implementation. It helps us feel more confident when the code later needs to be refactored or changed.…

StoreKit 2 Refresh Receipt

Even though StoreKit 2 keeps everything in sync automatically, the HIG still requires us to have Restore Purchase button. In Original API for In-App Purchase we’d either call SKRefreshReceiptRequest or restoreCompletedTransactions() on instance of SKPaymentQueue. In StoreKit 2 an equivalent to that would be AppStore.sync(). In regular operations, there’s no need to call sync(). StoreKit automatically…

TIL Xcode can Format to Multiple Lines

I’ve been coding a lot over the past few weeks, and much of the work was to make the code look better by formatting long lines into multiline. Like changing this: to this: It becomes tedious when needed to do a lot, so I’ve looked into automation. I believed I heard that Xcode added native…

TIL asl – Apple System Log

Today I noticed a strange behaviour in my Xcode’s console. I was testing iOS app background launch, more specifically, the case when the app is launched in background due to Watch Connectivity sendMessage method called on watchOS side. I was using “Wait for the executable to be launched” to get some console logs, but none…

Something went wrong. Please refresh the page and/or try again.


Follow My Blog

Get new content delivered directly to your inbox.

Leave a comment