mozilla / fx-private-relay

Keep your email safe from hackers and trackers. Make an email alias with 1 click, and keep your address to yourself.
https://relay.firefox.com
Other
1.44k stars 168 forks source link

call useMetrics hook to check FxA profile metricsEnabled #4824

Closed groovecoder closed 3 days ago

groovecoder commented 3 days ago

How to test:

  1. Since our local apps cannot receive webhook events from FXA, use the admin UI to update the SocialAccount for a user: In their "Extra data" field, edit the JSON to set "metricsEnabled": false
  2. Open the Network developer tool in a browser window
  3. Sign the user out and back into the app to make sure the front-end code has "fresh" profile data
    • [ ] On the resulting page, check the Network developer tool: there should be 0 requests to google-analytics or googletagmanager
  4. Repeat step 1 but edit the JSON to set "metricsEnabled": true
  5. Refresh the page
    • [ ] On the resulting page, check the Network developer tool: there should be 1+ requests to google-analytics or googletagmanager