Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Thinking metrics on React apps
Search
Jean Carlo Emer
October 27, 2016
Technology
190
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Thinking metrics on React apps
Jean Carlo Emer
October 27, 2016
More Decks by Jean Carlo Emer
See All by Jean Carlo Emer
Web & Mobile
jcemer
1
220
Cache em aplicações web
jcemer
0
340
Aplicações Web - um estudo sobre React
jcemer
1
220
Lapidando o Globo Play
jcemer
1
290
Desenvolvedor mobile precisa aprender Web
jcemer
1
160
Evolução e futuro do uso de paradigmas no JavaScript
jcemer
3
640
Tudo o que a web (podia ser) ainda será
jcemer
8
690
Embarque App
jcemer
0
510
Componentes para a web
jcemer
15
1.2k
Other Decks in Technology
See All in Technology
ミイダス株式会社 テックチームのご紹介 / MIIDAS Tech Team
miidas
0
150
ログラスのマルチプロダクトを 支える認証基盤 〜テナントごとに異なる統制とどう向き合うか〜
dada4386
3
390
ビジネスを止めない技術的負債の返済のための戦略とその手法 - 技術的負債と向き合う / Complexity and Simplicity
soudai
PRO
3
550
ai_cording_with_k8s_knowledge.pdf
mochizuki875
1
270
FactoryBotアンチパターン / factory_bot anti-patterns
toshimaru
0
130
転んだ話が背中を預ける理由になる / A_story_about_falling_down_gives_you_a_reason_to_watch_each_other_s_backs.pdf
pauli
2
200
自主式軟體工廠
philipz
0
220
[2026 Oracle Technical Deep Dive] エンタープライズAIエージェントを支えるOCIソリューション。ラインナップと特徴を理解しよう! (2026年9月17日開催)
oracle4engineer
PRO
0
500
HacobuにおけるFDEとは/登壇資料(戸井田 裕貴)
hacobu
PRO
1
770
Incremental HTTP
kazuho
5
2k
大阪オフィスに Unitree Go2 がやってきたので Physical AI やってみた
dafujii
0
300
Futexes the good, the bad, the ugly
ennael
PRO
0
120
Featured
See All Featured
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
320
Heart Work Chapter 1 - Part 1
lfama
PRO
10
36k
Lightning talk: Run Django tests with GitHub Actions
sabderemane
0
290
エンジニアに許された特別な時間の終わり
watany
109
250k
Leveraging LLMs for student feedback in introductory data science courses - posit::conf(2025)
minecr
1
420
What’s in a name? Adding method to the madness
productmarketing
PRO
24
4.2k
RailsConf 2023
tenderlove
30
1.6k
Jess Joyce - The Pitfalls of Following Frameworks
techseoconnect
PRO
1
430
Building Better People: How to give real-time feedback that sticks.
wjessup
370
20k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
31
3.4k
Everyday Curiosity
cassininazir
0
340
The Curse of the Amulet
leimatthew05
3
15k
Transcript
Thinking metrics on React apps @jcemer
I work on GloboPlay. globo.com
None
None
React Router 2.0 & Server side render & Client side
user login
1. How can we track our traffic with Google
Analytics?
<PageView location={this.props.location} />
@PureRender class PageView extends Component { static propTypes = {
location: PropTypes.object.isRequired } componentDidMount() { const { action, state } = this.props.location trackPageView(action, state) } componentDidUpdate() { /* */ } }
2. How can we analyse custom data?
Global metrics data: user account info & app version
<DocumentMetrics data={{ appVersion: "2.3" }} />
function handleStateChangeOnClient(vars) { setMetricsDataLayer(vars) } export default withSideEffect( reducePropsToState, handleStateChangeOnClient
)(DocumentMetrics) https://github.com/ gaearon/react-side-effect
3. How can we track the user navigation flow?
Playlist Recommendation
Component metrics: playlist or other lists
<Playlist /> <Recommendation /> <Video /> is a list of
<Video /> is a list of
<Playlist /> <Recommendation /> <Video metrics="playlist" /> is a
list of <Video metrics="recommendation" /> is a list of
<LinkMetrics data="playlist"> <Playlist /> </LinkMetrics> https://facebook.github.io/ react/docs/context.html
class Video extends Component { static contextTypes = { linkMetrics:
PropTypes.object } render() { const state = { metrics: this.context.linkMetrics } return <Link state={state}>/* ... */</Link> } }
* redux should be an option too
Components React side effect Context
Thank you! @jcemer