GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • QuickLayout Handbook
  • GitHub
  • Quickstart
  • Code Samples
  • How It Works
  • State Updates
  • Custom Content View
  • Experimentation
  • Tips
  • Traps
  • Manual Integration
  • UIViewControllers
  • HStack
  • VStack

This view

  • Original page
  • New address

GeezerVison is showing meta.github.io — Overview | QuickLayout

QuickLayout is a declarative layout library for iOS, designed to work seamlessly with UIKit. It is lightning-fast, incredibly simple to use, and offers a powerful set of modern layout primitives.

QuickLayout's API will feel natural to many iOS engineers. With a small and well tested codebase, it is production ready and the recommended declarative layout solution for Instagram.

Code Sample​

import QuickLayout

@QuickLayout
class MyCellView: UIView {

let titleLabel = UILabel()
let subtitleLabel = UILabel()

var body: Layout {
HStack {
VStack(alignment: leading) {
titleLabel
Spacer(4)
subtitleLabel
}
Spacer()
}
.padding(.horizontal, 16)
.padding(.vertical, 8)
}
}

Above is a fully functional view. Subviews are managed automatically, layout is performed at the correct time, and sizeThatFits returns an accurate value.

Features​

  • ⭐️ Lightning-Fast: Custom layout engine for blazing fast performance—no Auto Layout or Flexbox overhead.
  • 🧩 Modern Layout Primitives: Includes HStack, VStack, ZStack, Grid, and Flow as lightweight, pure Swift structs that don’t add extra views.
  • 🚀 Easy Integration: Simple @QuickLayout macro for fast setup and automatic subview management.
  • 🧵 Thread-Safe: With some caveats, our API can be used concurrently and off the main thread.

Motivation​

Declarative frameworks like SwiftUI have gained significant popularity in UI development due to their simplicity and expressive syntax. However, adopting these frameworks often requires developers to commit fully, leaving behind UIKit, which powers countless existing apps. This transition can be daunting, costly, and sometimes impractical for projects deeply embedded in UIKit.

QuickLayout is a new declarative library that brings the power of declarative syntax into the imperative world of UIKit. It is designed to work hand-in-hand with UIKit, ensuring you can easily mix and match declarative and imperative code. This hybrid approach means you can maintain your existing views while gradually transitioning to a more declarative style.

  • Code Sample
  • Features
  • Motivation
  • The Showcase App
  • Links
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.