GithubHelp home page GithubHelp logo

peretch / react-redux-comment-app Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 0.0 617 KB

In this app I'll practice using React, Redux, Jest and maybe other technologies.

License: MIT License

HTML 0.07% JavaScript 0.24% CSS 99.69%

react-redux-comment-app's Introduction

react-redux-comment-app

This app is designed to keep practicing with React, Redux, Jest and Enzyme.


Testing plan

Here we have what we should test in our app. In order to take the decision of what to test, we could think in this way:

  1. Look at each individual part of your application
  2. Imagine telling a friend what is the purpose of each piece of code.
  3. Write a test to verify each poart does what you expect

Components tests

App Component

  • Shows the comment textbox inside of it
  • Shows the comment list inside of it

CommentBox Component

  • Shows a text area and a button
  • Users can enter input and submit it
  • Text area is clean after input is submited

CommentList Component

  • Shows one <li> element for each comment
  • Text from each comment is visible

Redux tests

CommentsReducer

  • Propery hands actions with type 'SAVE_COMMENT'
  • Don't throw an application error if reducer gets an unknown action

SaveComment Action

  • Has a type of 'SAVE_COMMENT'
  • Produces an action that has a payload of the new comment's text

react-redux-comment-app's People

Contributors

peretch avatar

Watchers

 avatar  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.