Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Running
Using http-server to host the index.html created.
UI can be accessed on http://127.0.0.1:8080
Purpose:
This PR aims at creating a dashboard which allows used to maintain his own todo list.
Todos can be divided into 3 states as shown in the screenshot.
1. Draft
2. In Progress
3. Completed
Users can drag and drop todos from one state to another (Similar to JIRA dashboard). User is not allowed to back track the task state.
Key Points:
Have changed the implementation of Node Server for tasks CRUD operations.
Earlier tasks.json returned array of tasks which has now been changed to a Map of Tasks with key being the state of Tasks.
The above data structure reduces the lookup time for tasks from O(n) to O(1), since task can be looked upon using task Id in a map.
Update of a task is also a O(1) operation, since client can pass the type of the task which helps in directly updating the map.
Have used react-window FixedSizedList which is smaller implementation of react-virtualised which allows re use of DOM nodes and better rendering.
Have used FixedSizeList because the total number of tasks was pre calculated using the api, as it was returning the complete task object.
To prevent the bundle size from getting increased due to usage of react-window, We could also have implemented pagination in get tasks api which would always return a fixed number of tasks based on offset and page size.