GithubHelp home page GithubHelp logo

ricburton / stickylayout Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jeffreysfllo24/stickylayout

0.0 1.0 0.0 15.23 MB

Sticky Layout for UICollectionViews!

License: MIT License

Ruby 2.12% Swift 96.84% Objective-C 1.04%

stickylayout's Introduction

StickyLayout

codecov pod Badge w/ Platform License MIT

The above examples are accessible in the example folder.

What is StickyLayout?

StickyLayout is a collection view layout that provides sticky row and column configurability.

Features

  • Configurable Sticky options.
  • Pure Swift 5.
  • Horizontal and vertical scrolling support.
  • Row spacing and column spacing support.
  • Works with every UICollectionView.

Setup

Using StickyLayout quick and simple. First import StickyLayout.

import StickyLayout

You then have the option of creating an instance of StickyConfig, where you can specify which rows/columns you want to be sticky.

let stickyConfig = StickyLayoutConfig(stickyRowsFromTop: 1,
                                stickyRowsFromBottom: 0,
                                stickyColsFromLeft: 1,
                                stickyColsFromRight: 0)

let layout = StickyLayout(stickyConfig: stickyConfig)

Create an instance of StickyLayout with your StickyConfig as a parameter, and add it to your UICollectionView.

UICollectionView(frame: .zero, collectionViewLayout: layout)

Installation

StickyLayout is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod "StickyLayout"

Feedback and Suggestions

If you have any suggestions or improvements please open a pull request or create an issue.

And if you found StickyLayout useful or want to show support feel free to star this repo!

stickylayout's People

Contributors

jeffreysfllo24 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.