A Swift wrapper for Facebook's Yoga flexbox engine, providing a concise and chainable syntax for iOS layout.
FlexLayout is a Swift wrapper for Facebook's Yoga flexbox engine, providing a clean and chainable API for building responsive layouts in iOS apps. It solves the complexity and performance limitations of UIStackView by exposing the full power of CSS flexbox in a native Swift interface.
iOS developers building complex, responsive user interfaces who want a more performant and flexible alternative to UIStackView or manual Auto Layout.
Developers choose FlexLayout for its exceptional performance (up to 12x faster than UIStackView), intuitive syntax that mirrors flexbox structure, and seamless integration with the battle-tested Yoga engine from React Native.
FlexLayout adds a nice Swift interface to the highly optimized facebook/yoga flexbox implementation. Concise, intuitive & chainable syntax.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Benchmarks in the README show FlexLayout is 8x to 12x faster than UIStackView across various iPhone models, making it ideal for performance-critical interfaces.
The API uses fluent, chainable methods and a define() closure that visually mirrors the flexbox hierarchy, improving code readability and structure.
Supports all core flexbox properties including direction, justify, align, wrap, and RTL language support with start/end properties for internationalization.
Designed to work with PinLayout for mixed layout strategies, allowing developers to combine flexbox and absolute positioning in the same view.
FlexLayout does not implement the 'order' property, limiting dynamic reordering of items compared to web-based flexbox implementations.
Relies on Facebook's Yoga engine, which adds complexity in dependency management and potential issues with updates or compatibility.
Limited to UIKit-based iOS apps and does not integrate natively with SwiftUI, restricting its use in modern Apple development ecosystems.