Coder Social home page Coder Social logo

houston-codeo-messenger's Introduction

Houston Codeo Chat

Setup

Allowed Resources

  1. Your brain!
  2. No more than one page (front and back) of hand written notes
  3. The Debugger. Please run and debug your code
  4. The general internet

Banned Resources

  1. Other students
  2. Any prepared materials (besides notes)
  3. Any lessons
  4. Any solution code from any lab, whether you wrote it or Flatiron School did
  5. Code from any lecture

Cloning

  • Clone this repo down (don't fork!)
  • Create and checkout a branch before you start coding: git checkout -b "your-name"

Deliverables

This code challenge can be broken down into 7 steps. It is recommended that you commit after each step:

  1. Get messages by requesting it from the server
  2. Create a Message class, and use it to render each of the messages in a list
  3. Listen for when a user tries to add a new message
  4. When a user makes a message, Render the new message in the message list without refreshing the page
  5. When a user makes a message, Send the message to the server so that it persists
  6. Use setInterval to re-request the messages every 500 ms and re-render them in the list
  7. Refactor your code to make it as clean as possible

Getting the messages

The endpoint for getting image looks like this:

GET 'http://10.185.1.104:3000/messages'
Example Response:
[
  {
    "id": 1,
    "content": "Hello Houston Codeo!"
  }
]

If you cannot get your fetch request to work correctly, you can use the example response above to append content to the DOM and attempt the subsequent steps

Sending the messages

POST 'http://10.185.1.104:3000/messages'

Required keys in the body of the request:
{
  content: (insert message content here)
}

Required Headers
{
  'Accept': 'application/json',
  'Content-Type': 'application/json'
}

Submission

git add .

git commit -m "complete"

git push

houston-codeo-messenger's People

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.