Home

Awesome

<p align="center"> <a href="https://github.com/layoutBox/LayoutFrameworkBenchmark"><img src="docs_markdown/images/logo.png" alt="FlexLayout" width="270"/></a> </p> <h1 align="center" style="color: #376C9D; font-family: Arial Black, Gadget, sans-serif; font-size: 2em">Layout Framework Benchmark</h1> <p align="center"> <a href=""><img src="https://img.shields.io/cocoapods/p/FlexLayout.svg?style=flat" /></a> <a href="https://travis-ci.org/layoutBox/LayoutFrameworkBenchmark"><img src="https://travis-ci.org/layoutBox/LayoutFrameworkBenchmark.svg?branch=master" /></a> <a href="https://raw.githubusercontent.com/layoutBox/LayoutFrameworkBenchmark/master/LICENSE"><img src="https://img.shields.io/badge/license-New%20BSD-blue.svg?style=flat" /></a> </p> <br>

Benchmark the performances of various Swift layout frameworks.

Requirements

History <a name="history"></a>

This project is a spin-off of the excellent LayoutKit benchmark. The benchmark has been extracted to add other iOS layout frameworks and to compare them.

<br>

Why?

Choosing the right layout framework for your project is an important decision. The frameworks API is quite important, but its performance is also important. To help you with that decision, this benchmark compare different layout frameworks.

<br>

Benchmark charts

General comparison

This chart display a general comparison between device performance using each layout frameworks. It displays the performance when layouting UICollectionView cells. This graph shows performance when layouting 100 UICollectionView cells.

The Y axis indicates the number of seconds to render all cells.

<a href="docs_markdown/benchmark_comparison_all.png"><img src="docs_markdown/benchmark_comparison_all.png"/></a> <br>

Layout frameworks <a name="layout_frameworks"></a>

The benchmark currently includes the following layout frameworks:
(ordered alphabetically and use the framework GitHub's description):

:pushpin: Anyone who would like to integrate any other layout frameworks to this GitHub project is welcome.

<br>

Benchmark details

The benchmark layout UICollectionView cells in multiple pass, each pass contains more cells than the previous one.

Benchmark cell's layout

Here are the benchmark rendering results to compare visual results:

:pushpin: Some work would be required to adjust the layout so that they all match perfectly.

<br>

Benchmark data

You can see the benchmark's data and charts in this Google Spreadsheet Document.

<br>
Details for different devices

The X axis in following charts indicates the number of cells contained for each pass. The Y axis indicates the number of seconds to render all cells from one pass.

<a href="docs_markdown/benchmark_iphonexs.png"><img src="docs_markdown/benchmark_iphonexs.png"/></a> <br>

<a href="docs_markdown/benchmark_iphonex.png"><img src="docs_markdown/benchmark_iphonex.png"/></a> <br>

<a href="docs_markdown/benchmark_iphone7.png"><img src="docs_markdown/benchmark_iphone7.png"/></a> <br>

<a href="docs_markdown/benchmark_iphone6s.png"><img src="docs_markdown/benchmark_iphone6s.png"/></a> <br>

<a href="docs_markdown/benchmark_iphone6.png"><img src="docs_markdown/benchmark_iphone6.png"/></a> <br>

<a href="docs_markdown/benchmark_iphone5s.png"><img src="docs_markdown/benchmark_iphone5s.png"/></a> <br>

Project's TODO list

<br>

Contributing, comments, ideas, suggestions, issues, .... <a name="comments"></a>

For any comments, ideas, suggestions, simply open an issue.

If you'd like to contribute by adding other layout framework, you're welcomed!

<br>

Adding another layout framework

The process is currently tedious...

License

BSD 3-Clause License