Giter VIP home page Giter VIP logo

react_todo-app-with-api's Introduction

React Todo App with API (complete)

It is the third part of the React Todo App with API.

Take your code implemented for Add and Delete and implement the ability to toggle and rename todos.

Here is the working example

Toggling a todo status

Toggle the completed status on TodoStatus change:

  • covered the todo with a loader overlay while waiting for API response;
  • the status should be changed on success;
  • show the Unable to update a todo notification in case of API error.

Add the ability to toggle the completed status of all the todos with the toggleAll checkbox:

  • toggleAll button should have active class only if all the todos are completed;
  • toggleAll click changes its status to the opposite one, and sets this new status to all the todos;
  • it should work the same as several individual updates of the todos which statuses were actually changed;
  • do send requests for the todos that were not changed;

Renaming a todo

Implement the ability to edit a todo title on double click:

  • show the edit form instead of the title and remove button;
  • saves changes on the form submit (just press Enter);
  • save changes when the field loses focus (onBlur);
  • if the new title is the same as the old one just cancel editing;
  • cancel editing on Esс key keyup event;
  • if the new title is empty delete the todo the same way the x button does it;
  • if the title was changed show the loader while waiting for the API response;
  • update the todo title on success;
  • show Unable to update a todo in case of API error;
  • or the deletion error message if we tried to delete the todo.

Instructions

react_todo-app-with-api's People

Contributors

mhrynko avatar mgrinko avatar vitaliybondarenko1982 avatar solaryasha 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.