Open source Reddit client for iOS built entirely in Swift

Overview

Area51 App Icon

Area51

Build Status

Area51 is an open source Reddit client for iOS built entirely in Swift!

Get the public beta on TestFlight

Join the public Slack channel to collaborate!

Goals

  • Provide a beginner friendly development environment
  • Use the latest iOS development tools
  • Document everything! Helps beginners learn :)
  • Build an awesome open source Reddit client for iOS!

Getting Started

Requirements

Make sure you have Xcode: 10.2 or higher.

This project currently supports Swift 5.0+

Setup

Clone the repo and run the generate command:

git clone [email protected]:kgellci/Area51.git
cd Area51/
make generate

After generate is finished doing its job, open Area51.xcodeproj, build and run.

Project Structure

Area51 does not import any 3rd party libraries in app.

Xcodegen is used for project definition and generation.

Swiftlint is used to keep the code properly structured and readable.

Learn more about the project structure.

Running on a device

Make sure you run make generate command from above to generate the appropriate config files.

Edit the user.xcconfig file in the Configs/ directory (don't worry, it is gitignored!). Set DEVELOPMENT_TEAM in the user.xcconfig file. Example: DEVELOPMENT_TEAM = XXXXXXXXX

Edit the bundleIdentifier.xcconfig file in Configs/ directory (also gitignored!). Set PRODUCT_BUNDLE_IDENTIFIER in bundleIdentifier.xcconfig to something unique, Example: PRODUCT_BUNDLE_IDENTIFIER = whatever.i.want

You will need to close the Xcode project, run make generate and open the project again. You can find your team ID by logging into developer.apple.com.

FAQ

If you have more questions, check out the FAQ. If your question is not answered, open a new issue with the "Question" tag.

License

Area51 is licensed under the GNU General Public License v3.0. See LICENSE for more info.

Comments
  • [design] App Icon

    [design] App Icon

    We need an app icon else we can't distribute beta builds!

    Following Apples HIG for icon design is the best place to start!

    Appreciated files would be any of the following:

    • .sketch
    • .pdf
    • 1024x1024 .png
    design 
    opened by kgellci 11
  • Enable Explicit Self Swiftlint rule

    Enable Explicit Self Swiftlint rule

    https://github.com/realm/SwiftLint/blob/master/Rules.md#explicit-self

    Enable explicit self in our swiftlint usage. This will help keep the code across the project consistent and make it more clear in a function if a variable being accessed belongs to the class or is defined somewhere in the function.

    Instructions: https://github.com/realm/SwiftLint#configuration

    good first issue 
    opened by kgellci 8
  • Display preview of posts in Cells

    Display preview of posts in Cells

    It would be great to show a preview of the post (either a link or the description) under the title of the table view cells.

    This could be accomplished by using a cell preset with two labels.

    opened by bcye 7
  • Add community icons for subreddits

    Add community icons for subreddits

    Describe the solution you'd like Add community icons to the subreddits displayed in the Subreddits VC. Community icon urls are available in the default subreddit listings.

    Additional context Icons can be added to the tableview cell as shown in the screenshot below

    redditscreen

    enhancement 
    opened by dulithadabare 5
  • Show contributers avatars in contributers tableView

    Show contributers avatars in contributers tableView

    *add avatarUrl to contributer struct *decode contributer struct using codingkeys *add avatarImageView to ContributerCell *send avatarURL to avatarImageView to load image

    opened by mahmoudfotta 4
  • Add CoreAPI tests

    Add CoreAPI tests

    Here are some tests for CoreAPI. This tests the current behaviour, but I'd like to see this expanded in the future, as I'll mention below:

    Notes

    • I had to modify the getData(forRoute:parameters:completion) method to accept a mocked session. This doesn't affect the call site, thanks to default values.

    • CoreAPI currently just returns CoreAPIError.random if there is no data. I feel this would be better returning the actual error returned by the URLSession.dataTask.

    • Additionally, there may be some merit in using the status code from the URL response to check its in the 200-299 range.

    • I modified the Makefile to accept an array of test schemes, then look through them to run the tests.

    opened by squarefrog 4
  • Add Unit Test Target

    Add Unit Test Target

    As referenced in this issue I have no idea if this is the approach you are looking for, but its an approach at least!

    Notes:

    • I have no idea what the difference between Debug.xcconfig and area51-debug.xcconfig is. I chose Debug.xcconfig.

    • Example tests now run while Area51 target is set, and CMD+U pressed

    • Ideally, the window.rootViewController in AppDelegate should be overridden when testing, to speed up tests somewhat further down the line.

    • I have tested the target using fastlane scan and it executes the tests successfully, so there shouldn't be an issue setting this to run automatically on travis.

    opened by squarefrog 4
  • Add a search bar to search subreddits

    Add a search bar to search subreddits

    Is your feature request related to a problem? Please describe. I would like to add a search bar to the subreddit view to search for subreddits.

    Describe the solution you'd like I would like add a search bar to filter default subreddits.

    opened by dulithadabare 4
  • Separating the UITableView datasource from VC and make it reusable

    Separating the UITableView datasource from VC and make it reusable

    We should separate the UITableView's datasource from the UIViewController and try make it as reusable as possible.

    Changes to be made:

    • Separate the datasource from the FeedViewController (First 'test' case and example)
    • Make the new datasource reusable.

    Pros

    Anytime we need to display a list of common results (In this case, Listing) we do not need to setup the UITableView's datasource - we simply instantiate it and supply it a collection of Listing objects. The rest is taken care of.

    This will also separate the responsibilities a little more between the various UI layers. It as the added benefit that should we decide to change UI layout / implementation of a UITableViewCell for the given Datasource it will be all done in one place.

    Cons

    Don't see any immediate cons to this approach. It's an extra file in the project per datasource that we create - however I feel this is minor.

    As part of this change, I will also clean up the code in FeedViewController and make it ready for a review in the next day or two.

    I think we should use this as an example to implement other datasources for UiTableViews if accepted through a PR. We don't always have to aim for high reusability in every case - can judge that on a case by case basis.

    opened by RJ-Clegg 4
  • Add Unit tests

    Add Unit tests

    Since this project is aimed at beginners and show casing latest iOS development techniques; we should also include unit testing with this project.

    Thoughts?

    opened by RJ-Clegg 3
  • Add a TabBar as the root navigation

    Add a TabBar as the root navigation

    We should add a TabBarController with two tabs to start.

    • The first tab should hold the SplitViewController for the list of subreddits and feed.
    • The second tab should take you to a blank ViewController where we can turn it into a settings screen.
    opened by kgellci 3
  • Add a screen to view reddit posts natively

    Add a screen to view reddit posts natively

    Is your feature request related to a problem? Please describe. Currently, the reddit posts are viewed using a web view.

    Describe the solution you'd like Add a screen to view posts natively.

    Additional context The screen should display the following:

    • Post heading
    • Post OP
    • Post Body
    • Karma
    • Number of comments
    opened by dulithadabare 0
  • Add subreddit querying to SubredditService

    Add subreddit querying to SubredditService

    To the SubredditService module, add a method which takes a query string for the search term and returns a list of subreddits which match the query.

    You can do this by adding a new route to SubredditService/Sources/APIRoute+Subreddit.swift The route is subreddits/search

    You will then need to create a new api call in SubredditService module which uses CoreAPI.results... with the newly specified route. You will also need to pass through the query string as a parameter all the way through to CoreAPI which makes the call.

    opened by kgellci 1
  • Add support for Danger

    Add support for Danger

    As noted in https://github.com/kgellci/Area51/pull/83#issuecomment-468377696 it may be useful for someone to setup Danger.

    This would automate the initial QA of a Pull Request. It's easy to forget things sometimes, so this could automatically check the following:

    • Does SwiftLint pass?
    • Does it change significant parts of the app without unit tests?
    • Is the new code missing comments?
    • Have you updated the CHANGELOG?
    • Did you accidentally include a copyright header?

    This would probably need the project owner to setup, as it relies on a GitHub bot to run automatically. See Getting Started.

    opened by squarefrog 3
  • Create ListingViewModel and convert FeedViewModel to use

    Create ListingViewModel and convert FeedViewModel to use

    FeedViewModel has logic for formatting listings. It is doing this by mutating the Listing objects in place.

    https://github.com/kgellci/Area51/blob/master/Area51/Sources/ViewModels/FeedViewModel.swift#L37

    We should instead instantiate ListingViewModel from a listing which will apply the needed formatting to the required fields. We can probably convert ListingsDataSource to be a ListingViewModelDataSource which would give the added benefit of only formatting listings once instead of every time more listings are loaded.

    opened by kgellci 0
  • Improve displaying of the default subreddits

    Improve displaying of the default subreddits

    The "Default Feeds" are currently unordered and formatting doesn't look good. The default subreddits should be in an alphabetical order and formatted like /r/AskReddit instead of /r/AskReddit/.

    Screenshots

    simulator screen shot - iphone xs - 2019-02-22 at 21 19 13

    opened by lucashoeft 1
  • Add list of default subreddits

    Add list of default subreddits

    I think Reddit has sunset their default subreddits list, but we can still pre-populate the side navigation with a defaults list. Can probably start by using this one: https://www.reddit.com/r/defaults/comments/61mgs9/list_of_default_subreddits_26_march_2017/

    We can make the changes here for now: https://github.com/kgellci/Area51/blob/master/ListingService/Sources/Subreddit.swift

    I plan on refactoring to make less static fo future use but fine to use for now.

    good first issue 
    opened by kgellci 1
Owner
Kris
Kris
Open source SDK to quickly integrate subscriptions, stop worring about code maintenance, and getting advanced real-time data. Javascript / iOS glue framework

Open source SDK to quickly integrate subscriptions, stop worring about code maintenance, and getting advanced real-time data. Javascript / iOS glue framework

glassfy 5 Nov 7, 2022
An open-source Swift framework for building event-driven, zero-config Multipeer Connectivity apps

PeerKit An open-source Swift framework for building event-driven, zero-config Multipeer Connectivity apps Usage // Automatically detect and attach to

JP Simard 861 Dec 23, 2022
Login-screen-using-Swift - Firebase Apple Open Source Development

Firebase Apple Open Source Development This repository contains all Apple platfo

Kushal Shingote 1 Feb 3, 2022
SwiftCANLib is a library used to process Controller Area Network (CAN) frames utilizing the Linux kernel open source library SOCKETCAN.

SwiftCANLib SwiftCANLib is a library used to process Controller Area Network (CAN) frames utilizing the Linux kernel open source library SOCKETCAN. Th

Tim Wise 4 Oct 25, 2021
SkyWite is an open-source and highly versatile multi-purpose frameworks.

SkyWite is an open-source and highly versatile multi-purpose frameworks. Clean code and sleek features make SkyWite an ideal choice. Powerful high-level networking abstractions built into Cocoa. It has a modular architecture with well-designed, feature-rich APIs that are a joy to use.

SkyWite 24 Apr 22, 2022
A native, lightweight and secure time-based (TOTP) & counter-based (HOTP) password client built for iOS

A native, lightweight and secure time-based (TOTP) & counter-based (HOTP) password client built for iOS Built by Tijme Gommers โ€“ Buy me a coffee via P

Raivo OTP 770 Jan 8, 2023
A web API client in Swift built using Async/Await

Get A modern web API client in Swift built using Async/Await and Actors. let cli

Alexander Grebenyuk 745 Jan 3, 2023
Twitter-Client - A twitter client that allow users to view tweets on their iphone

Project 3 - Twitter Client Name of your app is a basic twitter app to read your

null 0 Feb 7, 2022
๐Ÿ“ฑ ย A strongly-typed, caching GraphQL client for iOS, written in Swift.

Apollo iOS is a strongly-typed, caching GraphQL client, written in Swift. It allows you to execute queries and mutations against a GraphQL server, and

Apollo GraphQL 3.6k Jan 7, 2023
To practice URLSession to fetch json data from open weather API

โ›…๏ธ weatherApp-iOS-practice ?? ๊ธฐ๋Šฅ ์ƒ์„ธ ๋„์‹œ ์ด๋ฆ„์„ ์ž…๋ ฅํ•˜๋ฉด ํ˜„์žฌ ๋‚ ์”จ ์ •๋ณด๋ฅผ ๊ฐ€์ ธ์™€ ํ™”๋ฉด์— ํ‘œ์‹œ๋˜๊ฒŒ ๋งŒ๋“ค์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค

Jacob Ko 0 Dec 18, 2021
Socket.io iOS and OSX Client compatible with v1.0 and later

SocketIO-Kit โš ๏ธ This project is no longer maintained. Please use the official framework Socket.IO-Client-Swift. SocketIO-Kit is a Socket.io iOS client

Ricardo Pereira 140 Mar 9, 2022
Frp Client Framework for iOS

Frp Client Framework for iOS README | ไธญๆ–‡ๆ–‡ๆกฃ base on https://github.com/fatedier/frp v0.37.1(the lastest at 2021.10) ios framework,it can run on your ip

zhouhao 5 Dec 13, 2022
Minecraft server RCON client for iOS/macOS

iRCON Minecraft server RCON client for iOS/macOS. Features Full remote console window Player list with ability to easily op, kick, ban, etc. Quickly s

JackMacWindows 7 Dec 26, 2022
SSH and SFTP client for iOS

Parrot.Flo SSH and SFTP client for iOS https://parrot-flo.site BUG ? Please Submit new issue Contact me Hey ? do you want ask about all my tools ? you

0x 4 Feb 16, 2022
The HTTP library used by the Spotify iOS client

Authentication and back-off logic is a pain, let's do it once and forget about it! This is a library that allows you to centralise this logic and forg

Spotify 625 Nov 20, 2022
This generic SOAP client allows you to access web services using a your iOS app, Mac OS X app and AppleTV app.

This generic SOAP client allows you to access web services using a your iOS app, Mac OS X app and Apple TV app. With this Framework you can create iPh

Prioregroup.com 479 Nov 22, 2022
An iOS library to route API paths to objects on client side with request, mapping, routing and auth layers

WANetworkRouting Developed and Maintained by ipodishima Founder & CTO at Wasappli Inc. Sponsored by Wisembly A routing library to fetch objects from a

null 10 Nov 20, 2022
iOS Project Manager Client

08-iOS-Project-Manager-Client ํ”„๋กœ์ ํŠธ ๋งค๋‹ˆ์ € STEP 1 ํ”„๋กœ์ ํŠธ ํ• ์ผ ๋ฆฌ์ŠคํŠธ ๊ธฐ๋Šฅ๊ตฌํ˜„ UI๊ตฌํ˜„๋ฐฉ์‹ : ์ฝ”๋“œ ์•„ํ‚คํ…์ณ : ProjectManagerViewController : NavigationViewController์œ„์— StackView(

Kioding87 1 Nov 19, 2021
The official iOS client library for api.video

api.video iOS client api.video is the video infrastructure for product builders.

api.video 8 Dec 2, 2022