This is a Node.js Acebook engineering project by pandas team. This project can be viewed locally, or is hosted at https://acebook-pandas.herokuapp.com/
It uses:
- Express web framework for Node.js.
- Nodemon to reload the server automatically.
- Handlebars to render view templates.
- Mongoose to model objects in MongoDB.
- ESLint for linting.
- Jest for testing.
- Cypress for end-to-end testing.
- Husky for pre-commit hook.
- Prettier to style code consistently.
- Bootstrap to make UI prettier.
- Bcrypt to store passwords safely.
- Nano ID to generate unique string for image names.
- Node Fetch to get login credentials from JSON file.
- Google Cloud Storage to upload images to the Google Cloud.
- Connect-multiparty to handle multipart forms (e.g. form for creating post with an image).
- As a user, so I can access my account, I would like to login.
- As a user, so I can login, I would like to sign up.
- As a user, so I can change accounts, I would like to log out.
- As a user, so I can share my opinion, I would like to upload posts (consisting of picture and text).
- As a user, so I can read other people's thoughts, I would like to view all posts (recent first).
- As a user, so I can stay up to date, I would like to see recent posts first.
- As a user, so I can navigate the site easily, I would like to have a navigation bar.
- As a user, so I can support an opinion, I would like to add a like to the post.
- As a user, so I can change my mind, I would like to remove my like from the post.
- As a user, so I can know who wrote a post, I would like to see their name next to it.
- As a user, so I can know who wrote a post, I would like to see their photo next to it.
- As a user, so I can introduce myself, I would like to enter info about me (DOB, bio and photo).
- As a user, so I can disscuss interesting topic, I would like to add a comment to a post.
- As a user, so I can support a comment, I would like to be able to like it.
- As a user, so I can correct my typos, I would like to edit my post or comment after posting.
- As a user, so I can redact my opinion, I would like to delete a post or comment.
- As a user, so everything looks good, I would like a nice UI.
npm install
Install and start MongoDB
brew tap mongodb/brew
brew install [email protected]
brew services start [email protected]
To start the server locally:
npm start
Browse to http://localhost:3000
Start a test server, then run the test suite
npm run start:test
This starts the server on port 3030
and uses the acebook_test
MongoDB database,
so that integration tests do not interact with the development server.
npm test