Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perf: 注文番号入力欄が重い問題を修正 #70

Merged
merged 1 commit into from
Nov 23, 2024

Conversation

r4ai
Copy link
Member

@r4ai r4ai commented Nov 23, 2024

This pull request makes several changes to the Reception component in the app/routes/reception.tsx file to refactor the handling of the tableNumber state. The most important changes include replacing the state with a reference and removing the associated state management code.

Refactoring state management:

  • Replaced the tableNumber state with a useRef hook to manage the table number input (tableNumberRef).
  • Updated the table number input field to use the tableNumberRef reference instead of state.
  • Removed the tableNumberChange function and the setTableNumber calls since the state is no longer used. [1] [2]

@r4ai r4ai requested review from sou1118 and Copilot November 23, 2024 04:40
@r4ai r4ai enabled auto-merge (squash) November 23, 2024 04:40

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 1 out of 1 changed files in this pull request and generated no suggestions.

Copy link
Member

@sou1118 sou1118 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@r4ai r4ai merged commit 21cecd1 into main Nov 23, 2024
6 checks passed
@r4ai r4ai deleted the feature/table-number-input-perf branch November 23, 2024 04:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants