File tree Expand file tree Collapse file tree 1 file changed +17
-0
lines changed
Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -93,9 +93,26 @@ function configurePostHog() {
9393
9494}
9595
96+ function initializeHubSpot ( ) {
97+
98+ if ( isLocalhost ) {
99+ console . log ( '[custom.js] Skipping HubSpot configuration on localhost' ) ;
100+ return ;
101+ }
102+
103+ var hubSpotScript = document . createElement ( "script" ) ;
104+ hubSpotScript . type = "text/javascript" ;
105+ hubSpotScript . id = "hs-script-loader" ;
106+ hubSpotScript . src = "https://js-na2.hs-scripts.com/244349038.js" ;
107+ hubSpotScript . async = true ;
108+ hubSpotScript . defer = true ;
109+ document . getElementsByTagName ( 'head' ) [ 0 ] . appendChild ( hubSpotScript ) ;
110+ }
111+
96112function initializeAll ( ) {
97113 initializeHockeyStack ( ) ;
98114 initializeReo ( ) ;
115+ initializeHubSpot ( ) ;
99116 configurePostHog ( ) ;
100117 if ( ENABLE_VOICE_WIDGET ) {
101118 injectVapiWidget ( ) ;
You can’t perform that action at this time.
0 commit comments