RichLinkComponent as an island - #3830
Merged
Merged
Conversation
oliverlloyd
requested review from
DavidLawes,
OllysCoding,
jlieb10 and
lucymonie
as code owners
January 13, 2022 14:44
oliverlloyd
marked this pull request as draft
January 13, 2022 14:45
|
Size Change: -28.3 kB (-1%) Total Size: 2.59 MB
ℹ️ View Unchanged
|
oliverlloyd
marked this pull request as ready for review
January 19, 2022 16:32
oliverlloyd
marked this pull request as draft
January 19, 2022 16:33
Contributor
|
part of #3629 |
oliverlloyd
marked this pull request as ready for review
January 20, 2022 10:37
OllysCoding
reviewed
Jan 20, 2022
| if (error) { | ||
| // Send the error to Sentry | ||
| window.guardian.modules.sentry.reportError(error, 'rich-link'); | ||
| window?.guardian?.modules?.sentry?.reportError(error, 'rich-link'); |
OllysCoding
approved these changes
Jan 20, 2022
OllysCoding
left a comment
Contributor
There was a problem hiding this comment.
+1 Lots of prop drilling but unavoidable! Looks good :)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this change?
This PR brings the
RichLinkComponentover to the island patternWhy?
To continue the work to remove App.tsx
ajaxUrlThis value was previously only used on the client but it is now needed on the server and, in order to make it available to the code which is rendering this element on the server, it needs to be prop drilled down