3DStreet / 3dstreet-editor

3DStreet Editor Repo
https://3dstreet.app
Other
18 stars 3 forks source link

instantiate and load google analytics from react app, not html tag #390

Closed kfarr closed 4 months ago

kfarr commented 5 months ago

I confirmed that we were sending events, but not to the development account as expected from the current environment file.

Then I identified that we're still loading GA via index.html https://github.com/3DStreet/3dstreet-editor/blob/master/index.html#L130

Instead we should instantiate google analytics via react / javascript so that we can use env credential to ensure that the current environment credentials are used to determine to which google analytics ID events are being sent.

Example: https://medium.com/finnovate-io/integrating-google-tag-manager-with-a-react-app-5a8584ee2251

Please make these changes on PR in progress #384

kfarr commented 4 months ago

closed by https://github.com/3DStreet/3dstreet-editor/pull/384