instagram-dogy
aka dodogy
a dogy themed instagram social network for messaging, posting updates, finding people and coloring the dog world.
code quality disclaimer
this repository marks the possibilities in flutter. it can surely influence a person to
leave the native/legacy code frameworks and add to the flutter state of art community.
features
- custom photo feed based on who you follow (using firebase cloud functions)
- post high quality videos and photo posts from camera or gallery
- like posts
- comment on posts
- view all comments on a post
- search for users
- notificaitons for likes, comments, follows, etc
- animations (heart when liking image)
- improved caching of profiles, images, etc.
- better post creation, add filters to your image
- custom camera implementation
- firebase security rules
- delete posts
- direct messaging
- stories
- profile pages
- follow / unfollow users
- change image view from grid layout to feed layout
- add your own bio
- activity feed showing recent likes / comments of your posts + new followers
screenshots
dependencies
- flutter
- firestore
- image picker
- google sign in
- firebase auth
- uuid
- dart image
- path provider
- font awesome
- dart http
- dart async
- flutter shared preferences
- cached network image
getting started
setup flutter
1.2. download the repo
$ vorishirne/instagram-dogy
$ cd instagram-dogy
3. setup the firebase app
- you’ll need to create a firebase instance. follow the instructions at https://console.firebase.google.com.
- once your firebase instance is created, you’ll need to enable google authentication.
- go to the firebase console for your new instance.
- click “authentication” in the left-hand menu
- click the “sign-in method” tab
- click “google” and enable it
- create cloud functions (to make the feed work)
- create a new firebase project with
firebase init
- copy this project’s
functions/lib/index.js
to your firebase project’sfunctions/index.js
- push the function
getfeed
withfirebase deploy --only functions
in the output, you’ll see the getfeed url, copy that. - replace the url in the
_getfeed
function infeed.dart
with your cloud function url from the previous step.
you may need to create the neccessary index by running firebase functions:log
and then clicking the link
if you are getting no errors, but an empty feed you must post photos or follow users with posts as the getfeed function only returns your own posts & posts from people you follow.
- enable the firebase database
- go to the firebase console
- click “database” in the left-hand menu
- click the cloudstore “create database” button
- select “start in test mode” and “enable”
- (skip if not running on android)
- create an app within your firebase instance for android, with package name com.yourcompany.news
- run the following command to get your sha-1 key:
keytool -exportcert -list -v
-alias androiddebugkey -keystore ~/.android/debug.keystore
- in the firebase console, in the settings of your android app, add your sha-1 key by clicking “add fingerprint”.
- follow instructions to download google-services.json
- place
google-services.json
into/android/app/
.
- (skip if not running on ios)
- create an app within your firebase instance for ios, with your app package name
- follow instructions to download googleservice-info.plist
- open xcode, right click the runner folder, select the “add files to ‘runner’” menu, and select the googleservice-info.plist file to add it to /ios/runner in xcode
- open /ios/runner/info.plist in a text editor. locate the cfbundleurlschemes key. the second item in the array value of this key is specific to the firebase instance. replace it with the value for reversed_client_id from googleservice-info.plist
double check install instructions for both
- google auth plugin
- firestore plugin
what’s next?
- notificaitons for likes, comments, follows, etc
- animations (heart when liking image)
- improve caching of profiles, images, etc.
- better post creation, add filters to your image
- custom camera implementation
- firebase security rules
- delete posts
- direct messaging
- stories
- clean up code
Comments are closed.