Open fehbari opened 1 year ago
I'm having the same issue. Is there a fix for this as of now?
@vabadio The way I'm working around it is by using the alternative call with event name + parameters object.
ReactGA.event('my_event_action', {
event_category: 'my_category',
event_label: 'my_label',
value: 'my_value',
non_interaction: true,
...otherParams, // optional
});
Everything is sent in the desired case that way.
With this call you can also send custom dimensions alongside the event (the ...otherParams
part).
@fehbari thank you so much!
Created a PR to support this either when creating ga4 instance or when calling the event() method
The original react-ga support a
titleCase
parameter when initializing. This doesn't seem to be present here. All my events are sent with a capitalized first letter.e.g.
this_event
ends up asThis_event
in Google Analytics.