twitter's People
twitter's Issues
Project Feedback!
Here are some general things that you can read through to evaluate your implementation:
- Did you minimize the number of public functions and properties in your classes? You should always try to minimize the number of properties and functions that are public or internal. This is a coding best practice.
- Is your TweetsViewController generic enough that it can be reused to display tweets from other Twitter endpoints? A view controller that displays a list of tweets is the type of view controller that you want to make generic enough that it can be used in multiple places throughout an app. This particular TweetsViewController can come in handy for displaying the user's home timeline, but can also be reused for displaying a list of tweets that mention the particular user, showing another user's timeline, etc.
- Did you properly handle the conditionally present label "retweeted by..." in your custom TweetCell? You'll notice that for some tweets you'll need to display the "retweeted by..." label and have this hidden for other tweets. You'll want to create an outlet for a top margin AutoLayout constraint and modify the constant depending on whether you want to show the label or not.
- Another common approach for implementing model classes Having model classes for both Tweets and Users and being able to initialize each one from a json dictionary makes it easier to handle the Twitter network response and turn it into model objects that can be reused throughout your app. It's also a good idea to check out libraries like Mantle which reduce the boilerplate code you need to implement these model classes.
- Did you handle reply/retweet/favorite actions from within the TweetCell? This is an example where it's useful for your model to be able to handle network actions, so you can simply wire up the buttons to a method like
[tweet retweet]
. You can even pass in an optional block if you want to handle a failure of the network event. - Did you immediately update the retweet and favorite counts when a user retweets or favorites a tweet? It's common practice when building an app to have actions like favoriting a tweet assume network success and ignore any failures. This gives the user an immediate response to his/her action without having to wait for a network response.
- Did you share code between your ProfileViewController and TimelineViewController? The
ProfileViewController
and theTimelineViewController
both contain a feed of tweets. There are three general strategies: you can have a single view controller that conditionally has the profile header, you can create the ProfileViewController as a subclass of the TimelineViewController, or you can create a separate class called a TimelineController (not a view controller). TimelineController is a dataSource and a delegate to a UITableView and knows how to show a feed of tweets. - Each Storyboard scene should have Auto Layout constraints specified for each view. There should be no yellow Auto Layout warnings, even if the layout seems to work. Auto Layout warnings are like having bad HTML. The browser will try to render it, and it might even look right, but it won't be fully predictable.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.