I am trying to add Google Analytics to a React Web Application.
I know how to do it in HTML/CSS/JS sites and I have integrated it in an AngularJS app too. But, I\'m not
If you prefer not to use a package this is how it can work in a react application. Add the "gtag" in index.html
In the submit action of the login form, fire off the event
window.gtag("event", "login", { event_category: "access", event_label: "login" });