Treads is a tiny but powerful social networking platform made with Node.js and MongoDB.
- Sign in using local authentication, Instagram or Google.
- Search for your other users.
- Chat with your friends in realtime.
- All feeds divided into 3 categories
- thoughts (tweets)
- events (location can be specified)
- moments (personal post)
- Like and comment on a feed.
- API for developers
- View your/others profile.
- Follow a particular user and get notified for his/her activities.
- Change your profile picture, bio, people who follow you etc.
- Electron app
And a lot more to be added soon...
- Fix Instagram/Facebook login (code ready / fix api)
- Activity feature for user to see follow requests and his/her daily activity.
- Notifications
- Maps showing status updates of people followed
- Node.js
- expressjs ExpressJS HTTP middleware
- ejs Embedded JavaScript templates
- MongoDB
Clone the repo locally then install all the dependencies using NPM
$ git clone https://github.com/axmachina/treads-social.git
$ cd treads-social
$ npm i
$ ./start.sh
Use *.sh scripts to manage app.
Before running, we need to add the Instgram and Google API Credentials to the project. Under the config
directory of the repo, you will find instagram.js
and google.js
. We need to add the <CLIENT_ID>
, <CLIENT_SECRET>
and <host>:<port>
with our own API credentials
/** REPLACE YOUR API CREDENTIALS HERE **/
var in_client_id = 'XXXXXXXXXXXXXXXXXX', // <CLIENT_ID>
in_client_secret = 'XXXXXXXXXXXXXXXXXXXX', // <CLIENT_SECRET>
Now Replace the <host>
& <port>
with the redirect uri specified in the Instagram API Dashboard and Google API Dashboard. Default is http://localhost:80/account/oauth
.
var in_redirect_uri = "http://localhost:80/account/oauth/:service";
Finally start the MongoDB server in a seperate bash/pm2
$ mongod
(can also use a cloud instance if local option is not available)
and then start the treads server via npm
.
$ npm start
The app uses mongoose as an ORM for performing CRUD operations on MongoDB and express.js for server-side HTTP routing.