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

Always show direct traffic in sources reports #2531

Merged
merged 4 commits into from
Dec 19, 2022

Conversation

ukutaht
Copy link
Contributor

@ukutaht ukutaht commented Dec 19, 2022

Removes query param show_noref which was used from React to control whether to show Direct / None traffic or not. The show_noref behaviour was untested previously.

The main visual change is that we used to not show Direct / None in sources list by default. It would only be shown when you clicked on 'details'. Now it's always shown:

Screenshot 2022-12-19 at 14 00 06

Closes #2523

Changes

Tests

  • Automated tests have been added

Changelog

  • Entry has been added to changelog

Documentation

  • This change does not need a documentation update

Dark mode

  • This PR does not change the UI

Removes query param show_noref which was used from React to control
whether to show Direct / None traffic or not. The show_noref behaviour
was untested previously.

Closes #2523
@bundlemon
Copy link

bundlemon bot commented Dec 19, 2022

BundleMon

Files updated (1)
Status Path Size Limits
static/js/dashboard.js
297.95KB (-41B -0.01%) -
Unchanged files (6)
Status Path Size Limits
static/css/app.css
515.19KB -
static/js/app.js
12.13KB -
static/js/embed.host.js
5.58KB -
static/js/embed.content.js
5.06KB -
tracker/js/plausible.js
748B -
static/js/applyTheme.js
314B -

Total files change -41B 0%

Final result: ✅

View report in BundleMon website ➡️


Current branch size history | Target branch size history


const detailed = this.showExtra()
api.get(`/api/stats/${encodeURIComponent(site.domain)}/${this.currentFilter()}`, query, {limit: 100, page, detailed, show_noref: true})
.then((res) => this.setState({loading: false, sources: sources.concat(res), moreResultsAvailable: res.length === 100}))
api.get(`/api/stats/${encodeURIComponent(site.domain)}/${this.currentFilter()}`, query, { limit: 100, page, detailed })
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sorry, the editor auto-formatted this file. Here's the real change.

showConversionRate() {
return !!this.props.query.filters.goal
}

fetchReferrers() {
if (this.props.query.filters.source) {
api.get(`/api/stats/${encodeURIComponent(this.props.site.domain)}/referrers/${encodeURIComponent(this.props.query.filters.source)}`, this.props.query, {show_noref: this.showNoRef()})
api.get(`/api/stats/${encodeURIComponent(this.props.site.domain)}/referrers/${encodeURIComponent(this.props.query.filters.source)}`, this.props.query)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Real change

@vinibrsl vinibrsl merged commit a37b343 into master Dec 19, 2022
@vinibrsl vinibrsl deleted the always-show-direct-traffic branch December 19, 2022 12:40
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.

Direct traffic missing from exported stats
2 participants