littlelink-server
littlelink-server copied to clipboard
[BUG REPORT] Button event tracking for Umami does not show up in dashboard
Buttons Relation
All buttons, including custom buttons
Bug Description
When including the 3 environment variables for Umami in the Dockerfile, the "name-button" events do not show up in the Umami dashboard:
- ENV UMAMI_WEBSITE_ID removed
- ENV UMAMI_APP_URL removed
- ENV UMAMI_SCRIPT_NAME script.js
Umami is set up since I am able to see stats come through. Event tracking is missing for buttons though.
Expected Result
Event tracking for the buttons should show up in the events tab when providing the UMAMI_WEBSITE_ID and the UMAMI_APP_URL.
Additional Information
No response
Images
No response
I've got the same issue - setup umami and normal tracking is working fine, but no event data is being tracked. Any update on this please? Thanks.
Sorry, I don't run umami so it's going to be up to someone who does to help with this one. One thing to check and verify is which events are getting sent (if any) in your browsers dev tools. It would help if someone could post the URL endpoint that event is calling along with the JSON payload and response. That might help others understand where the issue lies.
This exception is raised when clicking a button if you're using Umami:
Uncaught TypeError: window.umami is not a function
at onClick (umami.js:2:10)
at Object.Ec (react-dom.production.min.js:54:317)
at Fc (react-dom.production.min.js:54:471)
at react-dom.production.min.js:55:35
at kn (react-dom.production.min.js:105:68)
at An (react-dom.production.min.js:106:380)
at react-dom.production.min.js:117:104
at Jo (react-dom.production.min.js:274:42)
at wc (react-dom.production.min.js:52:375)
at _n (react-dom.production.min.js:109:469)
onClick @ umami.js:2
Ec @ react-dom.production.min.js:54
Fc @ react-dom.production.min.js:54
(anonymous) @ react-dom.production.min.js:55
kn @ react-dom.production.min.js:105
An @ react-dom.production.min.js:106
(anonymous) @ react-dom.production.min.js:117
Jo @ react-dom.production.min.js:274
wc @ react-dom.production.min.js:52
_n @ react-dom.production.min.js:109
Ge @ react-dom.production.min.js:74
Ue @ react-dom.production.min.js:73
Show 11 more frames
Show less
Thank you! This is helpful!
Doing some necro here. I've probaly found the issue.
In littlelink-server/src/analytics/umamis.js , you should change window.umami(e)
by umami.track(e)
@timothystewart6, I can fork and do the change though if you don't have time. Although I'm not a nodejs dev so it may require some confirmation
Tested it locally and on production umami, everything working flawlessly https://github.com/techno-tim/littlelink-server/pull/603
closed by https://github.com/techno-tim/littlelink-server/pull/603