Skip to content

Fix routing & fetching in Day View #1215

Description

@tyler-dane

Feature Description

There are a number of issues with how the /day view loads and keeps data in-sync.

Problem 1: Duplicate Routing code and competing abstractions

There are competing implementations for how to fetch events between the day and week views, which makes the code more difficult to maintain and understand.

Problem 2: After an event changes, the data on the day view is not updated

Refetch after websocket notification. Refine websocket notification to prevent refetch for changes that aren't related to the day in view

Implementation Plan

  • Refactor how day events are fetched, so that they can be fetched outside of the day view (useRefetch)
  • Refactor useRefresh so it's not coupled to the week view
  • Update day view to use the standard Redux pattern in the rest of this app
  • Abstract refetching to a route layout to reduce duplication

Use Case

This'll help users always see the accurate date when viewing the Agenda on the day view

Additional Context

Metadata

Metadata

Assignees

Labels

webFrontend/web related issue

Projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions