Parent
This is a child of #70272
Background
Inline selectors passed to useOnyx break memoization by creating a new function identity every render, causing unnecessary recomputations and re-renders. We’re standardizing selectors as first-class citizens to unlock recent useOnyx memoization improvements.
Goal
Refactor all inline selectors in this scope to one of:
- Shared selector: lives in
src/libs/onyx/selectors/<domain>/... when reused across components.
- Local selector: defined outside the component (same file) if only used by that file.
- Contextual selector: created with
useCallback (inside the component) only when it needs component data; dependency array must include that data.
Example implementation for the Session keys: #70264
Keys to handle
- Report name value pairs -
ONYXKEYS.COLLECTION.REPORT_NAME_VALUE_PAIRS — 9
- Personal details -
ONYXKEYS.PERSONAL_DETAILS_LIST — 3
- Last payment method -
ONYXKEYS.NVP_LAST_PAYMENT_METHOD — 2
- Transaction violations -
ONYXKEYS.COLLECTION.TRANSACTION_VIOLATIONS — 2
- Network -
ONYXKEYS.NETWORK — 1
- Blocked from chat -
ONYXKEYS.NVP_BLOCKED_FROM_CHAT — 1
- Report metadata -
ONYXKEYS.COLLECTION.REPORT_METADATA — 1
Upwork Automation - Do Not Edit
- Upwork Job URL: https://www.upwork.com/jobs/~021968348623335861237
- Upwork Job ID: 1968348623335861237
- Last Price Increase: 2025-09-17
Issue Owner
Current Issue Owner: @
Issue Owner
Current Issue Owner: @
Parent
This is a child of #70272
Background
Inline selectors passed to useOnyx break memoization by creating a new function identity every render, causing unnecessary recomputations and re-renders. We’re standardizing selectors as first-class citizens to unlock recent useOnyx memoization improvements.
Goal
Refactor all inline selectors in this scope to one of:
src/libs/onyx/selectors/<domain>/...when reused across components.useCallback(inside the component) only when it needs component data; dependency array must include that data.Example implementation for the Session keys: #70264
Keys to handle
ONYXKEYS.COLLECTION.REPORT_NAME_VALUE_PAIRS— 9ONYXKEYS.PERSONAL_DETAILS_LIST— 3ONYXKEYS.NVP_LAST_PAYMENT_METHOD— 2ONYXKEYS.COLLECTION.TRANSACTION_VIOLATIONS— 2ONYXKEYS.NETWORK— 1ONYXKEYS.NVP_BLOCKED_FROM_CHAT— 1ONYXKEYS.COLLECTION.REPORT_METADATA— 1Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @Issue Owner
Current Issue Owner: @