TinyConstraints - Nothing but sugar.

  •        27

tl;dr Nothing but sugar. TinyConstraints is the syntactic sugar that makes Auto Layout sweeter for human use.




Related Projects


  •    Javascript

AutoLayout.js implements Apple's Auto Layout and Visual Format Language in Javascript. Auto layout is a system which lets you perform lay out using mathematical relationships (constraints). It uses the awesome Cassowary.js library to do the actual constraint resolving and implements Apple's constraint system and Visual Format Language (vfl) on top of that. It supports the Extended VFL syntax, including view-stacks and z-indexing. AutoLayout.js is an abstract library for integrating Auto Layout and VFL into other javascript technologies. It provides a simple API and programming model that you can use to build your own auto layout and VFL solution. A simple example of this is, is using position: absolute; to lay out DOM elements. A more elobarate example of this is the Visual Format Editor, which is built using famo.us and famous-flex. AutoLayout.js is written in ES6 and contains transpiled distribution files.

Then - ✨ Super sweet syntactic sugar for Swift initializers

  •    Swift

✨ Super sweet syntactic sugar for Swift initializers. Initialize UILabel then set its properties.

Stevia - :leaves: Healthy Autolayout Sugar

  •    Swift

In the project folder, you can find an example of a typical login view laid out in both native and Stevia for you to understand and compare the two approaches.

Anima - Anima is chainable Layer-Based Animation library for Swift4.

  •    Swift

Anima is chainable Layer-Based Animation library for Swift4. It support to make sequensial and grouped animation more easily. is written as follows.

PureLayout - The ultimate API for iOS & OS X Auto Layout — impressively simple, immensely powerful

  •    Objective-C

The ultimate API for iOS & OS X Auto Layout — impressively simple, immensely powerful. PureLayout extends UIView/NSView, NSArray, and NSLayoutConstraint with a comprehensive Auto Layout API that is modeled after Apple's own frameworks. PureLayout is a cross-platform Objective-C library that works (and looks!) great in Swift. It is fully backwards-compatible with all versions of iOS and OS X that support Auto Layout. Writing Auto Layout code from scratch isn't easy. PureLayout provides a fully capable and developer-friendly interface for Auto Layout. It is designed for clarity and simplicity, and takes inspiration from the AutoLayout UI options available in Interface Builder while delivering far more flexibility. The API is also highly efficient, as it adds only a thin layer of third party code and is engineered for maximum performance.

BouncyLayout - Make. It. Bounce.

  •    Swift

BouncyLayout is a collection view layout that makes your cells bounce. The only you thing you need to do is import BouncyLayout, create an instance and add it to your UICollectionView.

Relayout - Swift microframework for declaring Auto Layout constraints functionally

  •    Swift

Relayout is a Swift microframework to make using Auto Layout easier with static and dynamic layouts. If you want to build a UI using Apple's UI frameworks today, you have three good options. You can use Auto Layout in Interface Builder, you can use Auto Layout in code and maintain references to those constraints, or you can implement a layout function with layoutSubviews. Each of these approaches has pros and cons.

Anchorage - A collection of operators and utilities that simplify iOS layout code.

  •    Swift

A lightweight collection of intuitive operators and utilities that simplify Auto Layout code. Anchorage is built directly on top of the NSLayoutAnchor API. Each expression acts on one or more NSLayoutAnchors, and returns active NSLayoutConstraints. If you want inactive constraints, here's how to do that.

cassowary.js - Cassowary/JS, better, faster, future-ready

  •    Javascript

Cassowary is an algorithm that computes flexible, responsive layouts quickly without resorting to piles of imperative code. Just describe the preferred relationships between values, noting which constraints are more important than others, and Cassowary figures out an optimal solution based on the current inputs. When the inputs or constraints change, Cassowary is particularly efficient at computing a new answer quickly based on the last-known solution. These properties together make it ideal for use in layout systems -- indeed, it's the algorithm at the center of Apple's new Auto Layout system for iOS & OS X. This repo hosts an improved version of Greg Badros's port of the Cassowary hierarchial constraint toolkit to JavaScript.

GrowingTextView - An UITextView in Swift3, Swift4 and Swift2

  •    Swift

An UITextView in Swift3, Swift4 and Swift2.3. Support auto growing, placeholder and length limit.

awesome-ios - A curated list of awesome iOS ecosystem, including Objective-C and Swift Projects

  •    Swift

A curated list of awesome iOS frameworks, libraries, tutorials, Xcode extensions and plugins, components and much more. The list is divided into categories such as Frameworks, Components, Testing and others, open source projects, free and paid services. There is no pre-established order of items in each category, the order is for contribution. If you want to contribute, please read the guide. Instabug has just released their visual repro steps feature to enable you to trace all the views that the user interacted with before a bug or a crash occured. This will help you reproduce bugs and fix them 10x faster. We highly recommend integrating Instabug’s framework as they compiled a lot of other great features like network logs and screen annotations, providing you with useful and rich data attached to each bug or crash report. Instabug is offering awesome-ios community an exclusive 15% discount on all paid plans. Go to 1 minute integration guide.

TZStackView - UIStackView replica for iOS 7.x and iOS 8.x

  •    Swift

A wonderful layout component called the UIStackView was introduced with iOS 9. With this component it is really easy to layout components in a row both horizontally and vertically. Apple recommends using the UIStackView wherever possible and resort to explicit NSLayoutConstraints only when there is no way to do it with UIStackView. This saves you lots of boiler plate NSLayoutConstraint creation code. UIStackView requires iOS 9, but we're not ready to make our apps require iOS 9+ just yet. In the meanwhile, we developers are eager to try this component in our apps right now! This is why I created this replica of the UIStackView, called the TZStackView (TZ = Tom van Zummeren, my initials). I created this component very carefully, tested every single corner case and matched the results against the real UIStackView with automated XCTestCases.

CompactConstraint - Simple NSLayoutConstraint expression parser for more readable autolayout code.

  •    Objective-C

A simple NSLayoutConstraint expression parser for more readable autolayout code. By Marco Arment and released under the MIT license (see LICENSE file). Apple's visual format syntax is helpful, but it cannot express all types of autolayout constraints, and it's not ideal for simple values. Creating NSLayoutConstraints manually is more powerful and covers all possibilities, but is extremely verbose and hard to read.

MotionMachine - A powerful, elegant, and modular animation library for Swift.

  •    Swift

MotionMachine provides a modular, powerful, and generic platform for manipulating values, whether that be animating UI elements or interpolating property values in your own classes. It offers sensible default functionality that abstracts most of the hard work away, allowing you to focus on your work. While it is type-agnostic, MotionMachine does support most major UIKit types out of the box and provides syntactic sugar to easily manipulate them. But it's also easy to dive in and modify for your own needs, whether that be custom motion classes, supporting custom value types, or new easing equations. Also check out the Examples project to see all the MotionMachine classes in action, or dive deep into the source Documentation.

Gemini - Gemini is rich scroll based animation framework for iOS, written in Swift.

  •    Swift

Gemini is rich scroll based animation framework for iOS, written in Swift. You can easily use GeminiCollectionView, which is a subclass of UICollectionView. It enables you to make multiple animation which has various and customizable properties, and moreover can create your own custom scroll animation.

anim - Swift animation library for iOS, tvOS and macOS.

  •    Swift

anim is an animation library written in Swift with a simple, declarative API in mind. It supports a bunch of easing functions and chaining multiple animations. It's a wrapper on Apple's UIViewPropertyAnimator on its core, and falls back to UIView.animate on versions before iOS and tvOS 10. It uses NSAnimationContext on macOS.

Viperit - Viper Framework for iOS using Swift v4

  •    Swift

Write an iOS app following VIPER architecture. But in an easy way. CocoaPods is a dependency manager for Cocoa projects.

FLKAutoLayout - UIView category which makes it easy to create layout constraints in code

  •    Objective-C

FLKAutoLayout is a collection of categories on UIView which makes it easy to setup layout constraints in code. FLKAutoLayout creates simple constraints with a readable syntax and provides many convenience methods to setup more complex constraints between multiple views at once. It automatically adds the constraints to the nearest common superview of the views involved and sets the translatesAutoresizingMaskIntoConstraints property on those views to NO.

WebCola - Javascript constraint-based graph layout

  •    TypeScript

JavaScript constraint based layout for high-quality graph visualization and exploration using D3.js and other web-based graphics libraries. Note: While D3 adaptor supports both D3 v3 and D3 v4, WebCoLa's interface is styled like D3 v3. Follow the setup in our homepage for more details.