I'm trying to configure google analytics for my react application. In my work I use the react-ga plugin. In all instructions they write that in the ReactGS.initialize() method, the arguments must be in the format UA-XXXXXX-XX, but for conversion, the format AW-XXXXXXXXX is needed. Code example in docs:
ReactGA.initialize('UA-000000-01');
In my case:
// initialize
App.js (main file)
useEffect(() => {
ReactGA.initialize('AW-XXXXXXXXX');
}, [params])
// call when event is done
api.js
POST METHOD
ReactGA.ga('event', 'conversion', {'send_to': 'AW-XXXXXXXXX/xxxxxxxxxxxxxxx'})
But code below is not working. Maybe someone had a similar problem and knows how to solve it