Swift tip: Building arrays with compactMap Jesse Squires demonstrates how we can use the Swift compactMap function to build arrays of optional items, while maintaining the intended order of the items. Posted on August 3, 2018 #compactMap #filter #array