Giter Site home page Giter Site logo

redux-mini-sprint's Introduction

Redux Mini Sprint

Topics

  • Actions
  • Reducers
  • The central store
  • Connecting React components to Redux

alt text

In this mini sprint, you'll be eased in the code base of a small Redux application. The application itself is a counter, with increment and decrement buttons. The increment button should increment the counter by 1. Conversely, the decrement button should decrement the counter by 1. The aim of this mini sprint is to familiarize you with the overarching data flow pattern of Redux, as well as exposing you to how Redux is typically hooked up to a React application.

To run the mini sprint code, npm install inside of the root directory, then npm start. You'll see that the application isn't working. There are a couple of spots that you'll need to fill in in the application in order to get it to function. These spots are in reducers/index.js, actions/index.js, and components/Counter.js.

The code is pretty heavily commented in order to try to clear up everything that is going on with the code that is provided for you. There is a decent amount of boilerplate when it comes to setting up a Redux application and hooking it up to React components, but the benefits that Redux gives you when it comes to predictability and simplicity of your data flow are worth it, especially when your application scales out and becomes much larger.

Take your time walking around the code base. There are lots of informative little tidbits in the comments that you won't want to miss. I highly encourage you to look at every file first before trying to write any code.

If you end up finishing quickly, you'll see there's a few extra credit prompts at the top of the Counter.js component file. Feel free to take a stab at implementing those. Or, you could take a look at the awesome Redux documentation here.

Good luck and have fun!

redux-mini-sprint's People

Contributors

seanchen1991 avatar

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.