### Install Sylius GTM Enhanced Ecommerce Plugin via Composer Source: https://github.com/stefandoorn/sylius-google-tag-manager-enhanced-ecommerce-plugin/blob/master/README.md This command adds the Sylius Google Tag Manager Enhanced Ecommerce plugin to your Sylius project using Composer, a dependency manager for PHP. It's the first step in integrating the plugin into your application. ```shell composer require stefandoorn/sylius-google-tag-manager-enhanced-ecommerce-plugin ``` -------------------------------- ### Configure UA and GA4 Enablement in Sylius GTM Plugin Source: https://github.com/stefandoorn/sylius-google-tag-manager-enhanced-ecommerce-plugin/blob/master/UPGRADE.md This YAML snippet demonstrates how to configure the enablement of Universal Analytics (UA) and Google Analytics 4 (GA4) within the `sylius_gtm_enhanced_ecommerce` plugin settings. Setting `ua` and `ga4` to `true` enables their respective tracking functionalities. ```yaml sylius_gtm_enhanced_ecommerce: ua: true ga4: true ``` -------------------------------- ### Access UA and GA4 Enabled Status in Frontend JavaScript Source: https://github.com/stefandoorn/sylius-google-tag-manager-enhanced-ecommerce-plugin/blob/master/UPGRADE.md These JavaScript variables provide frontend access to the enablement status of Universal Analytics (UA) and Google Analytics 4 (GA4) as configured in the Sylius GTM plugin. They are populated from global Twig variables, allowing conditional logic in client-side scripts. ```javascript var gtmEnhancedEcommerceUAEnabled = '{{ sylius_gtm_enhanced_ecommerce_google_ua }}'; var gtmEnhancedEcommerceGA4Enabled = '{{ sylius_gtm_enhanced_ecommerce_google_ga4 }}'; ``` -------------------------------- ### Basic Robots.txt Directives Source: https://github.com/stefandoorn/sylius-google-tag-manager-enhanced-ecommerce-plugin/blob/master/tests/Application/public/robots.txt This snippet provides a fundamental robots.txt configuration. It uses the 'User-agent: *' directive to apply rules to all web crawlers, allowing them full access to the site by default. The commented lines are informational references to official robots.txt and Google Webmaster guidelines. ```Robots.txt # www.robotstxt.org/ # www.google.com/support/webmasters/bin/answer.py?hl=en&answer=156449 User-agent: * ``` -------------------------------- ### Dump Sylius GTM Enhanced Ecommerce Plugin Configuration Reference Source: https://github.com/stefandoorn/sylius-google-tag-manager-enhanced-ecommerce-plugin/blob/master/README.md This command-line instruction uses the Symfony console to display the default configuration reference for the SyliusGtmEnhancedEcommercePlugin. It helps developers understand and customize the plugin's features by showing all available configuration options and their default values. ```shell bin/console config:dump-reference SyliusGtmEnhancedEcommercePlugin ``` -------------------------------- ### Load Sylius GTM Enhanced Ecommerce Plugin Bundle Source: https://github.com/stefandoorn/sylius-google-tag-manager-enhanced-ecommerce-plugin/blob/master/README.md This PHP code snippet registers the SyliusGtmEnhancedEcommercePlugin in your Sylius application's `bundles.php` file. Adding this line ensures that the plugin's services and functionalities are loaded and available across all environments. ```php StefanDoorn\SyliusGtmEnhancedEcommercePlugin\SyliusGtmEnhancedEcommercePlugin::class => ['all' => true], ``` -------------------------------- ### Supported Google Analytics 4 E-commerce Events Source: https://github.com/stefandoorn/sylius-google-tag-manager-enhanced-ecommerce-plugin/blob/master/README.md This section lists the Google Analytics 4 (GA4) e-commerce events supported by the plugin. These events are crucial for tracking various user interactions and e-commerce activities within the Sylius platform, enabling comprehensive analytics. ```APIDOC view_item view_item_list add_to_cart remove_from_cart view_cart begin_checkout add_shipping_info add_payment_info purchase ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.