Krisiacik/ImageViewer

An image viewer à la Twitter

Swift

2,541

189 commits

updated May 17, 2025

See the code

README

CI Status Swift 5.0 Carthage compatible Version Platforms iOS License MIT

Single image view

Gallery

For the latest changes see the CHANGELOG

Install

CocoaPods

pod 'ImageViewer'

Carthage

github "Krisiacik/ImageViewer"

Sample Usage

For a detailed example, see the Example!

// Show the ImageViewer with the first item
self.presentImageGallery(GalleryViewController(startIndex: 0, itemsDataSource: self))

// The GalleryItemsDataSource provides the items to show
extension ViewController: GalleryItemsDataSource {
    func itemCount() -> Int {
        return items.count
    }

    func provideGalleryItem(_ index: Int) -> GalleryItem {
        return items[index].galleryItem
    }
}

ImageViewer version vs Swift version.

ImageViewer 6.0+ is Swift 5 ready! 🎉

If you use earlier version of Swift - refer to the table below:

Swift versionImageViewer version
5.x>= 6.0
4.x5.0
3.x4.0
2.33.1 ⚠️
2.2<= 2.1

License

ImageViewer is licensed under the MIT License, Version 2.0. See the LICENSE file for more info.

Copyright (c) 2016 MailOnline

Krisiacik/ImageViewer

An image viewer à la Twitter

Swift

2,541

189 commits

updated May 17, 2025

See the code

README

CI Status Swift 5.0 Carthage compatible Version Platforms iOS License MIT

Single image view

Gallery

For the latest changes see the CHANGELOG

Install

CocoaPods

pod 'ImageViewer'

Carthage

github "Krisiacik/ImageViewer"

Sample Usage

For a detailed example, see the Example!

// Show the ImageViewer with the first item
self.presentImageGallery(GalleryViewController(startIndex: 0, itemsDataSource: self))

// The GalleryItemsDataSource provides the items to show
extension ViewController: GalleryItemsDataSource {
    func itemCount() -> Int {
        return items.count
    }

    func provideGalleryItem(_ index: Int) -> GalleryItem {
        return items[index].galleryItem
    }
}

ImageViewer version vs Swift version.

ImageViewer 6.0+ is Swift 5 ready! 🎉

If you use earlier version of Swift - refer to the table below:

Swift versionImageViewer version
5.x>= 6.0
4.x5.0
3.x4.0
2.33.1 ⚠️
2.2<= 2.1

License

ImageViewer is licensed under the MIT License, Version 2.0. See the LICENSE file for more info.

Copyright (c) 2016 MailOnline

Significant stargazers

Patrick Balestra

847 followers · starred Dec 2015

Andrea Mazzini

1,338 followers · starred Jan 2017

Damien

334 followers · starred Dec 2015

Dwight Watson

225 followers · starred Dec 2015