A social media platform for creatives to receive feedback on their works in progress.
Weeks 11-13 Student Project
Deployed on Netlify
Logo designed by Jessica Gooding
Kat - Scrum Master
Campbell - UX/UI lead
Hannah - DevOps lead
Jack - QA lead
- React
- Node
- Express
- PostgreSQL
- Jest
- Husky
- Codecov
- ES Lint
- Prettier
First draft protoyped in Figma for user testing
Add the following information into a .env
file inside the wip-rest-api/
folder:
PGDATABASE=wip_db
PGUSER=user
PGPASSWORD=password
JWT_SECRET=jwtsecret
git clone
this repo- cd into wip-app directory and
npm install
- Type in psql in terminal and hit enter.
CREATE USER user WITH PASSWORD 'password';
ALTER USER user WITH SUPERUSER;
Initialise the dev and test databases:
CREATE DATABASE wip_db WITH OWNER user;
CREATE DATABASE wip_test WITH OWNER user; -- database name is important for tests to run
\c wip_db;
\i database/init.sql;
\c wip_test;
\i database/init.sql;
- Ensure the test script in package.json refers to your local test database, i.e.
"scripts": {
"test": "PGDATABASE=wip_test jest src/test/*.test.js --watch"
}
- Run
npm test
to run tests inside wip-rest-api directory - Run
npm run dev
to start development server - If you are having issues with anything related to accessing the databases you have created, you may need to assign your user again:
ALTER DATABASE wip_db OWNER TO user;
You can set everything up using CLI from the project root.
npm run i-all
=> installs everything you need
npm run app
=> runs the front end on localhost:3001
npm run api
=> runs the back end on localhost:3000 (once you've set up your database)
Jest is used for all testing.
npm test
=> run tests for whole project; press q once you're happy with each review
npm run app-test
=> test just the front end
npm run api-test
=> test just the back end
REST API deployed on Heroku
You can make requests to the Heroku App URL, e.g. POST
to https://wip-rest-api.herokuapp.com/signup
π = Authorization required
Creates access token
Request body example:
{
"username": "username",
"email": "[email protected]",
"bio": "graphic design is my passion",
"vocation": "graphic designer",
"password": "password"
}
Receive access token
Request body example:
{
"username": "username",
"email": "[email protected]"
}
Get your user info when signed in
Update your user info
Request body example:
{
"bio": "I love Comic Sans",
"vocation": "graphic designer"
}
Get a project by project id
Get your watched (followed) projects
Get your own projects
Get your unwatched (unfollowed) projects
Add a new project to your account
Request body example:
{
"project_name": "new project",
"project_description": "first sketch, feedback welcome"
}
Get project steps by project id
Add project steps by project id
Request body example:
{
"step_name": "Sketch in pen",
"step_description": "Adding more details",
"step_link": "image.jpg"
}
Get feedback for step by step id
Add feedback for step by step id
Request body example:
{
"feedback": "wow, that's amazing!",
"tag": "compliment"
}
Update feedback by feedback id
Request body example:
{
"feedback": "wow, that's really amazing - keep up the good work!",
"tag": "compliment"
}
Start watching (following) a post by project id
Stop watching (following) a post by project id
Co-authored-by: Alexreid95 [email protected] Co-authored-by: Hannah Gooding [email protected] Co-authored-by: CampbellDocherty [email protected] Co-authored-by: Jack Heriz-Smith [email protected]