TriviaZone - A fun way of testing your knowledge

03 Dec 2017

The most difficult part before starting any project is to come up with something really interesting to work on. During my research for this project, I realized that my last two projects were confined to Books, and I wanted to expand further. I wanted to create something for everyone - lovers of painting, movies, books and programming like myself, etc. This is how I came up with the idea of creating TriviaZone, an application which is a combination of fun as well as learning experience.

What is TriviaZone? As the name suggests, this is an application that allows you to play or create your favourite trivia and compete for the top three positions on the Leaderboard.

From user’s point of view, this application provides user with multiple features:

  1. User can sign_up for an account or sign_in in case the account is already present.
  2. User can also sign_up or sign_in via Facebook.
  3. Once, signed in, User can see the scores of his or her previously played trivias.
  4. User is provided with options to Add a new Trivia, Play Trivia, Search Trivia or check the Leaderboard.
  5. The options of editing or deleting the trivia created by him/her are also provided . (User is not authorized to edit or delete trivia created by any other user.

TriviaZone is created on Ruby on Rails framework. The main challenges that I came across while working on this project were:

  1. Two levels of form nesting.
  2. The integration of gems devise and omniauth.
  3. Multiple routes needed nesting.
  4. Whitelisting of unpermitted strong parameters.
  5. Thinking of a way to capture the correct answers after the trivias were played.

After spending a lot of days debugging, reading and re-reading tutorials, I successfully overcame these challenges. Every hour spent was a great learning experience which left me with a little more knowledge than I had when I stared this project. I am over joyed with the fact that I decided to work on TriviaZone.

Check out the source code of TriviaZone here.