LOSTMOA Blog

  • Bringing Polymorphism to Codable

    A clean way to add polymorphic Codable support to Swift, avoiding the typical repeated custom decode/encode logic that slows us all down.

    Read more
  • Reducing the Codable boilerplate: Property Wrappers to the rescue

    We sometimes need to add a little bit of custom encoding logic. Property Wrappers enables this while still maintaining the very helpful automatic conformance to Codable provided by the Swift compiler.

    Read more
  • A better solution to SwiftUI List Reordering on macOS

    Drag based list re-ordering in SwiftUI on macOS adds a delay to all click operations such as focusing on a text field. In this post I describe how to add drag handles that allows us to avoid this focus delay and still use the simple SwiftUI .onMove method.

    Read more
  • KeyWindow a better way of exposing values from the Key window

    A new way of passing values to the commands section of a SwiftUI app even when the user is not focused on a text field.

    Read more
  • Reading from the Window in a SwiftUI lifecycle app

    Exploring how to access the hosting UIWindow & NSWindow in SwiftUI exposing its attributes and methods to your app.

    Read more
  • Customise About Panel on macOS in SwiftUI

    How to add custom information and copyright to your app's About window on macOS Big Sur when using the SwiftUI app lifecycle.

    Read more