vercel / vercel/hyper

Actions propagations of redux

Open
#3,471 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

🎨 Type: Enhancement 📊 Type: Performance
Dominant language
TypeScript
Stars
44.7k
Forks
3.6k
Avg merge
21m
Merged PRs (30d)
1

Description

  • I am on the latest Hyper.app version
  • I have searched the issues of this repo and believe that this is not a duplicate
  • OS version and name:
  • Hyper.app version:
  • Link of a Gist with the contents of your .hyper.js:
  • Relevant information from devtools (CMD+ALT+I on macOS, CTRL+SHIFT+I elsewhere):
  • The issue is reproducible in vanilla Hyper.app:

Issue

The current implementation of session is flawed. For example:

multiples_actions_invocations

You can clearly see that for each action for a window:

  • multiple session resize
  • session_add_data invoked while there is clearly no data being added.

By regrouping session_actions by window for resize event would mean 1 actions with all the session new size.

So when the window resize, we should batch update all the sessions at the same time. And only redrawing once, not after every action of the reducer.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the session_actions handling for window resize events and the reducer path described in the issue. Check how session resize and session_add_data are dispatched and how redraws are triggered. Done means resize actions are batched per window, all sessions update together, and rendering occurs once rather than after each reducer action.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, redux, typescript
Domain
frontend, performance
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.