I'm trying to add Google Analytics to my knack app. I tried following the post guides here, but when my knack javascript gets run, $('#knack-body') doesn't exist, so my google analytics script never gets run. Where is the element with id 'knack-body'?
Hey there,
There's actually no need to do anything with #knack-body. You can simply put this in your app's JavaScript, replacing UA-XXXXX-Y with your Google Analytics Tracking ID.
If you would like further help with this or anything else, feel free to contact me at david@hmnd.io! :)
(if the link above does not work, try: https://gist.github.com/hmnd/5d06856e4dec5edc6cecd69dd3d5f61c)