Coder Social home page Coder Social logo

fe_oct21-todos's Introduction

React dynamic list of TODOs

Description

You are given a basic markup for the App, TodosList and CurrentUser components and the API.

Add the data loading, so the App works as described below:

  1. Create a separate file api.ts to put all the API call there.
  2. Todos are fetched on page load from GET todos endpoint. (Use componentDidMount)
  3. Each todo has a button to select a user but selectedUserId is stored in the App. (pass a callback to the TodoList)
  4. CurrentUser component receives userId as a prop and loads user details from GET user endpoint (replace 1 with a given userId).
  5. If I select another user the details should be updated. (use componentDidUpdate).
  6. If I select the same user there should not be a request to the server.
  7. Add a button Clear into the CurrentUser to clear the selectedUser in the App
  8. Add an <input> to the TodoList to filter the todos by title
  9. Add a <select> to the TodoList to show all, active(not completed) or completed todos.
  10. (*) Add Randomize button to the TodoList to show the todos in a random order.

fe_oct21-todos's People

Contributors

mgrinko avatar danheim avatar mykola-yarchuk avatar danmysak avatar vpolets avatar irenhh avatar

Watchers

James Cloos avatar Yurii Holiuk 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.