AYImageKit is a Swift Library for Async Image Downloading, Show Name's Initials and Can View image in Separate Screen.

Overview

AYImageKit

AYImageKit is a Swift Library for Async Image Downloading.

Features

  • Async Image Downloading.
  • Can Show Text Initials.
  • Can have Custom Styles.
  • Can Preview Image In Separate Screen with Animation.
  • Can Show ActivityIndicator while image loading.
  • Can Add Placeholder Image.
  • Can Cache Image In Memory.
  • Can Cache Image In Disk.
  • Make Round Image.
  • Image Sharing Option.
  • Work Well in Table View and Collection View cell.

ScreenShot

alt text alt text

Installation

AYImageKit is only available via CocoaPods:

pod 'AYImageKit'

Usage

Via Storyboard.

  1. Add View in controller.
  2. Assign AYImageView Class to View.

alt text

In View Controller Class.

  1. If you only want to show Image.
import AYImageKit

class ViewController: UIViewController {
    
    @IBOutlet weak var imageView: AYImageView!
    
    override func viewDidLoad() {
        super.viewDidLoad()
    
        imageView.currentViewController = self
        imageView.setImageFromUrl(url: "your url link here")
        
    }
}
  1. If you want to show name's Initials in case of url broken or image is not available then.
imageView.currentViewController = self
imageView.text = "Adnan Yousaf"
imageView.setImageFromUrl(url: "your url link here")
       
  1. If you want to show placeholder Image in case of url broken or image is not available then.
imageView.currentViewController = self
imageView.placeHolderImage = UIImage(named: "")
imageView.setImageFromUrl(url: "your url link here")
       
  1. If you want to get image then use completion handler.
imageView.setImageFromUrl(url: "your url link here") { result in
            switch result {
            case .success(let image):
                self.imageView.setImage(image)
            case .error(let error):
                print(error.localizedDescription)
            }
        }
       
  1. If you want to set Image directly.
imageView.currentViewController = self
imageView.setImage(UIImage(named: ""))
       
  1. If you want to set name's initials only.
imageView.showInitialsName("Adnan Yousaf")
       
  1. Cache Properties
imageView.cacheInDisk = false
imageView.cacheInMemory = false
       
  1. Styling
imageView.updateStyle(with: Style(font: UIFont.systemFont(ofSize: 34),
                                          textColor: UIColor.white,
                                          background: UIColor.black,
                                          borderColor: UIColor.black))
       
  1. Further Customization
imageView.isCircular = true
/// if `true` AYImageView will be in circular shape. Default is `false`

imageView.isAllowToOpenImage = true 
// if `true` AYImageView will be interactive and can open ImageViewer. Default is `true`

imageView.isSharingEnabled = true 
// if `true` ImageViewerViewController will show a button to share image. Default is `true`

imageView.isShowActivityIndicator = true 
//if `true` AYImageViewer will show activity indicator during downloading image. Default is `true`

imageView.imageContentMode = .scaleAspectFill 
// set Image content mode of imageView. Default is `scaleAspectFit`

imageView.isforceRemoteFetchingEnabled = false 
//if `true` ImageDownloader will download image whether image is present in cache or not. Default is  `false`
   

For more Detail See Example project.

Contributing

  • If you want to contribute, submit a pull request.
  • If you found a bug, have suggestions or need help, please, open an issue.
  • If you need help, write me: [email protected]

License

AYImageKit is released under the MIT license.

You might also like...
Swift image slideshow with circular scrolling, timer and full screen viewer
Swift image slideshow with circular scrolling, timer and full screen viewer

🖼 ImageSlideshow Customizable Swift image slideshow with circular scrolling, timer and full screen viewer 📱 Example To run the example project, clon

Image slide-show viewer with multiple predefined transition styles, with ability to create new transitions with ease.
Image slide-show viewer with multiple predefined transition styles, with ability to create new transitions with ease.

ATGMediaBrowser ATGMediaBrowser is an image slide-show viewer that supports multiple predefined transition styles, and also allows the client to defin

A simple Image full screen pop up
A simple Image full screen pop up

CLImageViewPopup Description A simple UIImageView for easy fullscreen image pop up. No matter where your UIImageView may be. Image pops up from where

SwiftUI  project to show ActivityIndicator above Image while loading
SwiftUI project to show ActivityIndicator above Image while loading

ImageWithActivityIndicatorDemo SwiftUI project to show ActivityIndicator above Image while loading ImageWithActivityIndicatorDemo is a demo app that s

A simple Image full screen pop up
A simple Image full screen pop up

CLImageViewPopup Description A simple UIImageView for easy fullscreen image pop up. No matter where your UIImageView may be. Image pops up from where

A custom ImageView that is used to cover the surface of other view like a scratch card, user can swipe the mulch to see the view below.
A custom ImageView that is used to cover the surface of other view like a scratch card, user can swipe the mulch to see the view below.

MCScratchImageView GIF Showcase Requirments iOS 8.0+ Xcode 7.2+ Swift 4.0 Installation CocoaPods pod "MCScratchImageView" Manually Just drag MCScratch

An image download extension of the image view written in Swift for iOS, tvOS and macOS.
An image download extension of the image view written in Swift for iOS, tvOS and macOS.

Moa, an image downloader written in Swift for iOS, tvOS and macOS Moa is an image download library written in Swift. It allows to download and show an

AsyncImage before iOS 15. Lightweight, pure SwiftUI Image view, that displays an image downloaded from URL, with auxiliary views and local cache.

URLImage URLImage is a SwiftUI view that displays an image downloaded from provided URL. URLImage manages downloading remote image and caching it loca

Rounded async imageview downloader lightly cached and written in Swift
Rounded async imageview downloader lightly cached and written in Swift

PASImageView ============ **Rounded async imageview downloader lightly cached and written in Swift 3 ** Objective-C version here Snapshot Usage //XIB

Releases(1.0)
Owner
Adnan Yousaf
Adnan Yousaf
🍁🥓 Lightweight and fast Swift library for image downloading, caching and transformations

MapleBacon Introduction MapleBacon is a lightweight and fast Swift library for downloading and caching images. Example The folder Example contains a s

Jan Gorman 335 Nov 1, 2022
A high-performance image library for downloading, caching, and processing images in Swift.

Features Asynchronous image downloader with priority queuing Advanced memory and database caching using YapDatabase (SQLite) Guarantee of only one ima

Yap Studios 72 Sep 19, 2022
Kingfisher is a powerful, pure-Swift library for downloading and caching images from the web

Kingfisher is a powerful, pure-Swift library for downloading and caching images from the web. It provides you a chance to use a pure-Swift way to work

Wei Wang 20.9k Dec 30, 2022
Media view which subclasses UIImageView, and can display & load images, videos, GIFs, and audio and from the web, and has functionality to minimize from fullscreen, as well as show GIF previews for videos.

I've built out the Swift version of this library! Screenshots Description ABMediaView can display images, videos, as well as now GIFs and Audio! It su

Andrew Boryk 80 Dec 20, 2022
Flower classifier predicting the names of over 70 different types.

Fløra Lab Table of Contents Project Onboarding Installation Swift Playgrounds iPad Mac Xcode Copyright Project Fløra Lab is a flower classification ap

Lukman Aščić 4 Jun 6, 2022
A complete Mac App: drag an image file to the top section and the bottom section will show you the text of any QRCodes in the image.

QRDecode A complete Mac App: drag an image file to the top section and the bottom section will show you the text of any QRCodes in the image. QRDecode

David Phillip Oster 2 Oct 28, 2022
An extremely high-performance, lightweight, and energy-efficient pure Swift async web image loader with memory and disk caching for iOS and  Watch.

KFSwiftImageLoader KFSwiftImageLoader is an extremely high-performance, lightweight, and energy-efficient pure Swift async web image loader with memor

Kiavash Faisali 343 Oct 29, 2022
Lightweight and customisable async image loading in SwiftUI. Supports on-disk storage, placeholders and more!

Asyncrounously download and display images in Swift UI. Supports progress indicators, placeholders and image transitions. RemoteImageView Asyncrounous

Callum Trounce 192 Dec 7, 2022
Async image downloader with Mem&Disk cached as a UIImageView extension

HBWebImage Example To run the example project, clone the repo, and run pod install from the Example directory first. Requirements Installation HBWebIm

haoboxuxu 1 Oct 22, 2022
An instagram-like image editor that can apply preset filters passed to it and customized editings to a binded image.

CZImageEditor CZImageEditor is an instagram-like image editor with clean and intuitive UI. It is pure swift and can apply preset filters and customize

null 8 Dec 16, 2022