Google Analytics works locally but not on shinyapps.io

Hello,

My application sends data to Google Analytics Realtime if it is run locally, but not if its deployed instance is accessed on shinyapps.io. This article was used as a reference for embedding the tracking code. A Property was created in Google Analytics with the tracking id and URL specified.

I am also experiencing this problem with my app deployed in shinyapps.io and am hoping to see if anyone else has come to a solution for this.