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

feat!: Remove RecommendationsPanel #437

Merged
merged 4 commits into from
Aug 28, 2024
Merged

Conversation

MaxFrank13
Copy link
Member

Removes the RecommendationsPanel widget. See the below links for more information

Discourse thread

DEPR ticket #410

@MaxFrank13 MaxFrank13 requested a review from a team as a code owner August 27, 2024 15:31
Copy link

codecov bot commented Aug 27, 2024

Codecov Report

Attention: Patch coverage is 0% with 2 lines in your changes missing coverage. Please review.

Project coverage is 97.24%. Comparing base (00129bc) to head (b038813).
Report is 1 commits behind head on master.

Files Patch % Lines
src/widgets/LookingForChallengeWidget/track.js 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #437      +/-   ##
==========================================
+ Coverage   95.73%   97.24%   +1.51%     
==========================================
  Files         163      154       -9     
  Lines        1452     1378      -74     
  Branches      244      228      -16     
==========================================
- Hits         1390     1340      -50     
+ Misses         58       36      -22     
+ Partials        4        2       -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

Choose a reason for hiding this comment

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

Question, and maybe not a fair question.

What is different about this track.js call for it to be separate from all the other trackers in src/tracking/trackers/?

Copy link
Contributor

Choose a reason for hiding this comment

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

This brings up a good point actually.

I believe the reason why this track.js file existed was because all of the components in the /widgets directory were business code, and so as an attempt to "separate" any business logic from core logic, that included separating the trackers as well.

After this PR is merged, there will be a /widgets directory that is made up of an AppWrapper that doesn't do anything (it used to hold the Painted Door Experiment logic) and a basic LookingForAChallenge component that will no longer be a child of the RecommendationsPanel.

I don't think it needs to be a part of this PR, but I do think there's a cleanup opportunity to remove the /widgets directory and move LookingForAChallenge to live inside /src/containers/WidgetSidebar.

Copy link
Contributor

Choose a reason for hiding this comment

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

Actually, I think it'd fit in the best while resolving this issue: #336

Copy link
Contributor

Choose a reason for hiding this comment

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

OK, I won't be a blocker on this then. Thanks for the insight, Jason!

Copy link
Member Author

Choose a reason for hiding this comment

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

This track.js file is actually new as the LookingForChallengeWidget was using an event from within the RecommendationsPanel which seemed like a not-so-great pattern. So I just made this to be a track file specific to LookingForChallengeWidget and figured we could leave the rest up to #336 if there was more cleanup to be done w.r.t. event code.

I don't think it needs to be a part of this PR, but I do think there's a cleanup opportunity to remove the /widgets directory and move LookingForAChallenge to live inside /src/containers/WidgetSidebar.

Agreed 1000%.

I'll also add that there is this issue #385 that proposes potentially removing the widgets pattern in favor of using FPF for business specific code.

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah, I think this further drives the point that the widgets pattern can be switched out for the PluginSlots pattern anyways. Neat!

Copy link
Contributor

@justinhynes justinhynes left a comment

Choose a reason for hiding this comment

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

Seems straight forward enough to me! Thanks for the cleanup here.

@MaxFrank13 MaxFrank13 merged commit f836239 into master Aug 28, 2024
6 of 7 checks passed
@MaxFrank13 MaxFrank13 deleted the mfrank/remove-recs-panel branch August 28, 2024 13:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants