Skip to content

katie80/Hackathon

Repository files navigation

Know Your Code

  • By Burlywood

##Level subjects:

  • HTML ✅
  • CSS ✅
  • JavaScript
  • jQuery
  • Node
  • Mongo
  • Mongoose
levels = [ {level} ]

level = {title: "level 1",
         question: "string",
         options: [{option}]
       }

option = {content: "string",
           isCorrect: boolean}

The JSON:

{"title": "Level 1: HTML",
"question": "question_content",
"options": [{"content": "option_1_content",
           "isCorrect": true},
           {"content": "option_2_content",
           "isCorrect": false},
           {"content": "option_3_content",
           "isCorrect": false}]
}

Instructions for setting up Know Your Code full-stack application development environment

  1. Initialize node application
  2. Install express, body-parser and mongoose
  3. Make a directory for data
  4. Start mongodb poitnted to data directory
npm init
npm install --save express body-parser mongoose prismjs
mkdir data
mongod --dbpath ./data

With your mongo data base running in one terminal, open another with command-n, navigate to your local Know Your Code Full-stack folder and run server.js

Intstructions for building Levels

  1. Set up development Environment
  2. In sublime, open hackathon/know-your-code-fullstack/public/levelmaker.html
  3. Insert level dependent information into divs (first answer div always contains correct answer)
  4. For options containing code blocks,
  5. Use https://tohtml.com/ to generate styled html and
  6. Insert styled html into answer divs
  7. Add font-size styleing depending on code block size
  8. Manualy add indentation on a line by line basis.
  9. In your browser, navagate to localhost:8000/levelmaker.html
  10. Visualy inspect render and make additional edits if needed
  11. Once satisfied with level, Click add level to save level to database.

At the end of a session

  1. Finalize your levels collection using robomongo (delete unwanted levels/duplicates)
  2. Click save levels to json to export your levels into the leves.json file

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors