-
Notifications
You must be signed in to change notification settings - Fork 429
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
remove mysql page view tracking #2750
Conversation
closes steemit/steempunks#321
remove page_view api resource
do not try to display a page view count
only record page views to overseer
src/app/utils/ServerApiClient.js
Outdated
if (last_page_promise && page === last_page) return last_page_promise; | ||
if (window.ga) { | ||
// virtual pageview | ||
window.ga('set', 'page', page); | ||
window.ga('send', 'pageview'); | ||
} | ||
api.call('overseer.pageview', { page, referer: ref, account }, error => { | ||
// if (error) console.warn('overseer error', error, error.data); | ||
last_page_promise = api.callAsync('overseer.pageview', { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does this need to be wrapped in a process.env.BROWSER
check?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, good point :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
err actually oddly enough we're fixing a previous bug here; looks like we have been double-recording ssr pageviews to overseer !
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@roadscape "fixed"
className="PageViewsCounter" | ||
title={tt('g.views', { count: views }) + suffix} | ||
> | ||
<Icon name="eye" /> {views.toLocaleString()} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if we might reuse this at some point we should keep the render function
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just because classnames, css, icon are all known working
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i'd rather not include it as commented code; we can find the old markup here in git
Code looks good, let's merge after dev test |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Removing views is a nice change. This was becoming a very wrong number with the emergence of new apps on the steem blockchain. |
closes steemit/steempunks#321
remove page_view api resource
do not try to display a page view count
only record page views to overseer