openedx / openedx/paragon

Consider removing `withDeprecatedProps` HOC

Open
#2,486 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

code health discovery
Dominant language
JavaScript
Stars
140
Forks
100
Avg merge
1h 3m
Merged PRs (30d)
30

Description

Paragon uses withDeprecatedProps HOC in multiple components to notify users about deprecated props. However, this creates some size overhead for the components where it is used, which may negatively impact consuming applications' bundle size, even though this HOC has no effect in production mode.

### Tasks
- [ ] Consider whether `withDeprecatedProps` HOC is worth keeping in the codebase. Is there a way to remove it from production bundle and use only during the development mode? Alternatively, Is there a way to notify consumers of deprecated props without this HOC?

Contributor guide

Open the contributing guide

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 with src/withDeprecatedProps.tsx and inspect the components that use this HOC. Measure its production bundle impact and investigate whether development-only warnings or another consumer notification approach is feasible. Done means the codebase has a decided approach, with the production-bundle behavior and deprecation notifications addressed accordingly.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.