iOS application - Github Search Repository Client - Using Swift Programming language.
This Project uses the Swift Package Manager for its dependencies.
(What is Swift Package Manager? The Swift Package Manager is a tool for managing the distribution of Swift code. It’s integrated with the Swift build system to automate the process of downloading, compiling, and linking dependencies.)
Add a Swift Package Dependency
To add a package dependency to your Xcode project, select File > Swift Packages > Add Package Dependency and enter its repository URL. You can also navigate to your target’s General pane, and in the “Frameworks, Libraries, and Embedded Content” section, click the + button, select Add Other, and choose Add Package Dependency.
The app uses three dependencies:-
-
Kingfisher: A lightweight and pure Swift implemented library for downloading and caching image from the web.
-
Loaf: A simple framework for easy iOS Toasts (to show Error messages)
-
SwiftyJSON: SwiftyJSON makes it easy to deal with JSON data in Swift
The app has two pages:-
- Repo Search: It searches using the keyowrd entered by user, Once a keyword is entered, it searches the repository on Github using the API (api.github.com)
- Repo details: It shows meta data about the selected repo, such as, Repo name, owner, creation date, description etc.,
It uses UITableView - UITableViewDataSourcePrefetching protocol, You use a prefetch data source object in conjunction with your table view’s data source to begin loading data for cells before the tableView(_:cellForRowAt:) data source method is called.
func tableView(_ tableView: UITableView, prefetchRowsAt indexPaths: [IndexPath])
- Xcode 12 or later &
- iOS 13 or later
- Swift 5 and above