]> _ Git - cubist_cms-front.git/commitdiff
#2609
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Fri, 22 Feb 2019 14:07:28 +0000 (15:07 +0100)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Fri, 22 Feb 2019 14:07:28 +0000 (15:07 +0100)
src/FrontServiceProvider.php
src/config/googletagmanager.php [new file with mode: 0644]

index f3b9a227fd30907c1ff5f1fde0ce7bd95f7cca3a..f7bd338f6b654a9f39b2b0da763d754cea2e35f5 100644 (file)
@@ -22,11 +22,12 @@ class FrontServiceProvider extends ServiceProvider
             $this->loadViewsFrom($customViewsFolder, 'cubist');
         }
         // - then the stock views that come with the package, in case a published view might be missing
-        $this->loadViewsFrom(realpath(__DIR__.'/resources/views'), 'cubist');
+        $this->loadViewsFrom(realpath(__DIR__ . '/resources/views'), 'cubist');
 
         // publish config file
-        $this->publishes([__DIR__.'/config/cubist-front.php' => config_path('cubist-front.php')], 'config');
+        $this->publishes([__DIR__ . '/config/cubist-front.php' => config_path('cubist-front.php')], 'config');
+        $this->publishes([__DIR__ . '/config/googletagmanager.php' => config_path(__DIR__ . '/config/googletagmanager.php')], 'config');
         // publish the views
-        $this->publishes([__DIR__.'/resources/views' => resource_path('views/vendor/cubist/front')], 'views');
+        $this->publishes([__DIR__ . '/resources/views' => resource_path('views/vendor/cubist/front')], 'views');
     }
 }
\ No newline at end of file
diff --git a/src/config/googletagmanager.php b/src/config/googletagmanager.php
new file mode 100644 (file)
index 0000000..07595f6
--- /dev/null
@@ -0,0 +1,27 @@
+<?php
+
+return [
+
+    /*
+     * The Google Tag Manager id, should be a code that looks something like "gtm-xxxx".
+     */
+    'id' => env('GOOGLE_ANALYTICS_ID', ''),
+
+    /*
+     * Enable or disable script rendering. Useful for local development.
+     */
+    'enabled' => env('GOOGLE_ANALYTICS_ID', '') != '',
+
+    /*
+     * If you want to use some macro's you 'll probably store them
+     * in a dedicated file. You can optionally define the path
+     * to that file here and we will load it for you.
+     */
+    'macroPath' => '',
+
+    /*
+     * The key under which data is saved to the session with flash.
+     */
+    'sessionKey' => '_googleTagManager',
+
+];