Comments (4)
Actually looks like my pageviews aren't working either. If anyone can help me out, would be greatly appreciated!
from redux-beacon.
Ahh, didn't have the segment script loaded in my html head. It's late =/
from redux-beacon.
Hahaha @zachrnolan no worries, happens to all of us!
On a serious note, this makes me think we should throw a little warning or an error to the console warning devs that they probably haven't added the segment tag to their page. Here's what I'm thinking.
- Add a test here. The test would set
window.analytics = undefined
, and it wouldexpect(() => Segment()).toThrow('some helpful error message')
. Very similar to the check we have in the Google Analytics target (last test). - In the target, write a check to ensure that if the window is defined, then
window.analytics
exists. If it doesn't then throw the error. Make the test pass.
Let me know if you want to take this on. If not, then I'll make an issue for it.
from redux-beacon.
Thanks for the outline @ttmarek, I went ahead and created a PR for this here: #108. Let me know if any improvements can be made.
from redux-beacon.
Related Issues (20)
- Redux Beacon Google Tag Manager docu down HOT 2
- trackException() sending incorrect fields object HOT 2
- Support for react-native-google-analytics-bridge version 6 HOT 1
- How are we meant to test this? HOT 1
- [TypeScript] Add support for typings in EventDefinition HOT 3
- Documentation request: please remove the Github Pages docs HOT 3
- Documentation Bug: Broken links on readme.md HOT 1
- How to track external link when each link has its own metadata? HOT 3
- trackEvent eventDefinition not showing the correct parameters HOT 1
- Gtag, access user-id config inside redux-beacon, React HOT 3
- [Typescript] combineEvents forces invalid type HOT 1
- Error when trying to track e-commerce items in GA following documentation HOT 1
- Update docs for usage with React Native + Segment HOT 1
- Add Matomo (formerly Piwik) support HOT 2
- Integration with Redux Dynamic Modules HOT 1
- Distribute as ES module HOT 1
- IP anonymization with Google Analytics (gtag) HOT 2
- Any Event [*] is invoked for all events even though the exact key match present HOT 1
- @amplitude/analytics-browser support
- Offline storage doesn't persist events
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from redux-beacon.