Our monthly GitHub digest is back, and today we’re talking about new Swift and Objective-C libraries that can make the life of an iOS developer easier.
Swift, ~2k stars this month
GodEye is an open source collection of Swift libraries that allows you to automatically display logs, crash, networking, CPU, RAM, and networking information – and more. It has a very comprehensive structure and contains multiple sub-projects. There’s even a book about the development process of this huge utility tool. To be clear, the book is in Chinese, but it’s a great idea.
Writing a single line of code is enough to implement GodEye in your project. GodEye includes not only libraries for monitoring your app but also a user interface for displaying information.
When to use:
When you want to display all debugging information in a convenient format.
Swift, ~1.5k stars this month
Spruce is a lightweight, user-friendly library that helps developers synchronize, manage, and launch chained animations that display on the screen in a fixed order. Spruce can keep developers from cringing when designers request complex multi-view animations for a prototype.
When you try to animate some view, you might not know if this view is already prepared for the given animation. For example, if you need to fade in a view, you need to be sure that this view was faded out previously. Spruce gives us the ability to skip this routine just by calling yourView.spruce.prepare(ourAnimations).
As for animation choreography, you can use different sort functions to line up your transitions. To apply a sort function, just use yourView.spruce.animate([.fadeIn, .expand(.slightly)], sortFunction: sortFunction)
As you can see, this library provides an easy-to-navigate interface for developers that is based on natural speech patterns: you can command your view to “slide up slightly” or “expand moderately.”
When to use:
When you want to create complex multiple-view animations that run simultaneously.
Objective-C, ~1k stars this month
IPAPatch allows developers to inject changes into existing .ipa-files using the powerful Objective-C runtime. Using this library, developers can build, run, debug and even link external frameworks to third-party apps. IPAPatch allows developers to implement changes to a UI and even add new UI elements to an existing app. The only restriction is that these changes will only be displayed on a particular device, and the updated version of the app doesn’t get transferred to the App Store.
With IPAPatch, all you need to improve your app is:
Xcode project IPAPatch
Decrypted .ipa file
Some free time :)
When to use:
When you want to implement a slight change or addition to an iOS application that is already installed on a device.
Swift, ~900 stars in the past 2 weeks
The Request Permission project offers a solution for managing permissions. On top of allowing developers to request permissions, the tool also includes a customizable UI element that developers can embed in their application. This element provides a welcome alternative to default iOS permission requests.
A stylish and user-friendly dialog increases the chances that your users will grant your app the necessary permissions. The simple control that this module provides can save hours of development time. Developers can request any permissions with just two lines of code:
var permissionAssistant = SPRequestPermissionAssistant.modules.dialog.interactive.create(with: [.Camera, .PhotoLibrary, .Notification]) permissionAssistant.present(on: self)
After that, every time developers want to know if they’ve been granted a certain permission, they can call the following method:
let isAvailableCamera = permissionAssistant.isAllowPermission(.Camera)
When to use:
When you need to receive permissions from users to enable certain features in your app.