iOS Data Visualization Library
How we brought Datadog’s data visualization to iOS: A focus on performance | Datadog

How we brought Datadog’s data visualization to iOS: A focus on performance | Datadog

4/18/2024 · Yassir Ramdani, Austin Lai

What this post added

This post details the development of DogGraphs, an internal iOS data visualization library using Swift and SwiftUI. It highlights the challenges of building a performant graphing solution for complex Datadog data on iOS, especially with constraints like iOS 14 compatibility and the absence of native charting libraries at the time of inception. The article explains the library's API design, leveraging Swift's result builders, and its integration into various Datadog mobile products. A significant portion is dedicated to performance optimization strategies, including the use of _printChanges() and Xcode Instruments to identify and resolve SwiftUI view body evaluation bottlenecks and slow function calls. The post emphasizes the importance of profiling during key events like initial rendering, updates, and environment changes.

Read the original post ↗