generated from microverseinc/readme-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
To-Do-list/src/modules/addItem.js
Line 5 in 7109b17
| export let arrayOfTasks = JSON.parse(localStorage.getItem('arrayOfTasks')) || []; |
- It is Javascript's best practice to use the
constkeyword for declaring an array.
To-Do-list/src/modules/addItem.js
Line 22 in 7109b17
| if (taskInput.value !== '') { |
- Try not to use negative condition in the conditional statement and also instead of writing
!==' 'inside theifblock conditiontaskInput.value
To-Do-list/src/modules/addItem.js
Line 29 in 7109b17
| localStorage.setItem('arrayOfTasks', JSON.stringify(arrayOfTasks)); |
- In lines 29, 41, 52 instead of writing Local storage again and again try to use the function and call that function.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels