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

[RUMF-621] set view referrer to the previous view URL #507

Merged
merged 7 commits into from
Aug 26, 2020

Conversation

BenoitZugmeyer
Copy link
Member

Motivation

For route_change views, use the previous view URL as referrer.

Changes

For the sake of simplicity, lifecycle types have been improved a bit so we can re-use them easily. Then, the referrer has been set to the View context so it can be used everywher the View context is used. Finally, the view collections is retrieving the previous view URL when creating the new view on URL change or session renew.

Testing


I have gone over the contributing documentation.

@BenoitZugmeyer BenoitZugmeyer requested a review from a team as a code owner August 25, 2020 15:44
Copy link
Contributor

@mquentin mquentin left a comment

Choose a reason for hiding this comment

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

with Small NIT

packages/rum/src/rum.ts Outdated Show resolved Hide resolved
@codecov-commenter
Copy link

codecov-commenter commented Aug 26, 2020

Codecov Report

Merging #507 into master will increase coverage by 0.33%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #507      +/-   ##
==========================================
+ Coverage   87.61%   87.94%   +0.33%     
==========================================
  Files          35       35              
  Lines        2156     2157       +1     
  Branches      434      434              
==========================================
+ Hits         1889     1897       +8     
+ Misses        267      260       -7     
Impacted Files Coverage Δ
packages/rum/src/lifeCycle.ts 100.00% <ø> (ø)
packages/rum/src/parentContexts.ts 98.24% <ø> (ø)
packages/rum/src/rum.entry.ts 73.21% <ø> (ø)
packages/rum/src/userActionCollection.ts 98.00% <ø> (ø)
packages/rum/src/rum.ts 91.47% <100.00%> (+4.65%) ⬆️
packages/rum/src/viewCollection.ts 96.29% <100.00%> (+0.03%) ⬆️
packages/rum/src/performanceCollection.ts 63.33% <0.00%> (+1.66%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3e11e98...691c0c9. Read the comment docs.

Copy link
Contributor

@bcaudan bcaudan left a comment

Choose a reason for hiding this comment

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

Nice job!

@BenoitZugmeyer BenoitZugmeyer merged commit f555b65 into master Aug 26, 2020
@BenoitZugmeyer BenoitZugmeyer deleted the benoit/view-referrer branch October 20, 2020 17:33
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.

4 participants