Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*Chirper Design Phase
- Come up with the schema for the twitter application.
- - URL structure for all directories
- - All objects you will be storing in firebase
- - All properties of those objects
- - Pay attention to casing and the data type (especially on dates) of properties
- Requirements:
- - CRUD on tweets
- - CRUD for friends
- - CRUD for Profile
- - Read Friends tweets
- - On initial page, load your tweets and sort them by timestamp
- - A timeline page, which shows all tweets from all friends sorted by timestamp (should use polling)
- - Search Tweets
- */
- //Shared Firebase - profiles
- //Must have exact same property names
- var myProfile=(firstName, lastName, displayName, imageUrl, email, status, firebaseUrl, friends[profile keys of friends in array//], profileKey) {}
- //First, get ALL PROFILES through shared firebase
- //display my friends feed:
- //Loop through the friends array
- //for each friend, retrieve the firebaseUrl from the friend by key comparison looping through ALL PROFILES,
- //and perform an AJAX call to their firebase to grab their tweets. push the tweets in to a Javascript array in local memory
- //Sort the tweets by reverse datetime order
- //display the results to screen
- //Individual firebase
- app.Message =function(author, createDate, modifyDate, body, background-color, font, text-color, key);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement