Giter Site home page Giter Site logo

building-forms-lab-web-100817's Introduction

Set List Lab

Objectives

  1. Use forms to create new elements and update the store.
  2. Display a list of the new elements in a separate component.

Overview

Guess what - the bands are back! What we want is an application that allows us to add band names, and then have those band names instantly rendered below. We need to be incorporating Redux by dispatching actions and updating the store each time someone submits a new band.

So we will be creating two different React components each of them need to connect to our Redux store. One of the components will be a form where we input our band name, and the other component will display the list of bands.

The createStore method and some basic setup has already been implemented for you.

Instructions

  1. You will need to write the BandInput component. The component should have a form with a text input and submit button. We would like to update the component's state each time the user types a new character in the input. However, we only update the store's state when the user hits the submit button.
  • Note: To have access to the store's dispatch method, we pass through the entire store as a prop.
  1. You will need to write the Bands component. This component should display a ul with a list element for each of the bands in the store's state. Each list element should have text with the corresponding name of the band.

  2. You will also need to fill in the manageBand reducer located under ./src/reducers/manageBand.js. It will need to respond to an action of type 'ADD_BAND' and correspondingly concatenate a new band each time the action is dispatched.

building-forms-lab-web-100817's People

Contributors

aturkewi avatar jeffkatzy avatar kwebster2 avatar lukeghenco avatar nikymorg avatar slin12 avatar

Watchers

 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.