This project is a small full stack web application ... in this web app you can share facts with other people and learn new facts which are being posted by other people
Having created the website from scratch, I learned how to create and implement features that I'm likely to use in my future websites over and over again. Here are some of the key features and topics that I worked on:
- Facts can be shared with source and categories
- Fact list can be shortlisted according to the categories
- Users can react on facts
- Three reaction categories are there :
- like 👍
- mindblowing 🤯
- wrong ⛔
- If there is high amount of wrong reactions on a fact the fact gets listed as
[⛔DISPUTED]
- If there is a error in the new fact input field it gets marked by light red shade
- Fully responsive thanks to media queries
- Utilized flex-box and absolute positioning
- Loading... animation that matching with the color scheme of site
- error and no data for a certain category showing when there is an error loading data from the database and the database contains no data for certain category respectively
To deploy the project yourself you just need to do as follows:
we would be using vercel
to deploy the project
- Fork the project to your github
- now you can clone it to your pc using git clone command(optional)
- open the src directory and open supabase.js file
- here put the supabase url and api key accordingly in the mentioned places
to create a table in supabase follow as below - create a new project
- now in the project open table editor and create a new table
- name the new table facts
- there would be two columns id and created_at by default
add columns with the names and Types as follows :
name type Default Value text text - source text - category text - votesInteresting int8 0 votesMindblowing int8 0 votesFalse int8 0
- now you can save the table
- once you create the table go to authentication section > policies
- for the facts table add new policy and enable read , write , update for everyone
- now go to settings section > api
- there you will find project url copy and paste that in supabase.js
- now in the api section you will find Project API keys from there copy the public anon api key and paste in the supabase.js in appropriate place
- now save everything and commit to your github repo ... you are done with setting up supabase
- once done with the above steps successfully ... open vercel.com and create a account (you can use github for fast signup)
- now in the projects create a new project and connect your factly github repo in your account
- now set a name for your project
- click on build and deploy
- wait for the webapp to be deployed once its deployed you will see the link in your vercel project
- Congratulation your personal factly is now deployed