Update with more optimistic updates

This commit is contained in:
2021-11-21 16:52:56 +01:00
parent bb99f99a22
commit 3c5fe488cd
11 changed files with 80 additions and 2874 deletions

View File

@@ -21,7 +21,9 @@ export const TodoItem: FC<TodoItemProps> = (props) => {
<div
className="py-3 border-b border-gray-300 dark:border-gray-600 relative"
onMouseEnter={() => {
prefetchTodo(props.todo.id);
if (!props.todo.id.startsWith("temp")) {
prefetchTodo(props.todo.id);
}
setIsHovering(true);
}}
onMouseLeave={() => setIsHovering(false)}