Skip to content

Releases: inpsyde/google-tag-manager

3.0.0-beta.1

25 Jul 14:03
b598265
Compare
Choose a tag to compare
3.0.0-beta.1 Pre-release
Pre-release

Refactor DataLayer and Collectors

The DataLayer and DataCollectors were refactored and are now required to be registered to the Service\DataCollectorRegistry which is being used by the DataLayer. Additionally, the Collectors are not require anymore to implement enabled() and isAllowed(). The DataLayer itself will contain the state of "enabled/disabled" of Collectors. Additionally, Collector:data() can now return null, when the current view does not generate any data.

Settings revamp

The Settings have been completely rewritten and are now managed with Gutenberg Components on the page. A new REST Endpoint has been introduced which is being used to get and update the settings.

More (breaking) changes

  • The AuthorDataCollector has been merged with the PostDataCollector.
  • RendererProvider does not resolve dependencies lazy and not directly on registration.
  • Http\Request has been removed.
  • A new SearchDataCollector has been introduced.
  • DataCollectorInterface has now "id()", "name()" and "description()" as new methods.

Removed dependencies

Following dependencies have been removed from the Plugin:

  • inpsyde/assets
  • chrico/wp-fields
  • brain/wp-nonces

Raise of required versions

PHP is now required in at least v8.1 and Node in v18.

E2E Testing

E2E Testing with playwright has been added to the repository and is being executed in a GitHub Action through wp-env.

Quality

  • All PHP GA are now using min PHP 8.1
  • All Node GA are now using Node 18.

What's Changed

Full Changelog: 2.2.0...3.0.0-beta.1

2.2.0

12 Jul 11:01
Compare
Choose a tag to compare

What's Changed

New Contributors

Full Changelog: 2.1.0...2.2.0

2.1.0

19 Sep 06:46
854bba0
Compare
Choose a tag to compare

2.1.0

Pre-compiled assets available in assets-2.1.0.zip.

2.0.0

28 Jun 06:54
94fa669
Compare
Choose a tag to compare

Breaking changes

This version removes the custom psr/container-implementation and upgrades to inpsyde/modularity as base.

You now need to use inspyde/modularity to hook into the Plugin like following:

<?php

use Inpsyde\Modularity\Package;

use function Inpsyde\GoogleTagManager\plugin;

add_action(
    plugin()->hookName(Package::ACTION_INIT),
    static function (Package $plugin): void {
       $plugin->addModule(new MyModule());
    }
);

Read more about "Access from external" in our documentation: https://inpsyde.github.io/modularity/Package/#access-from-external.

Removed BootstrapEvent

Due the change to inpsyde/modularity, we now no longer need Inpsyde\GoogleTagManager\Event\BootstrapEvent::ACTION.

Removed ConfigBuilder and PluginConfig

Those 2 classes were no longer needed. We can now use the Inpsyde\Modularity\Properties\PluginProperties to access all required data.

Restructure of code

The code structure is now more flat which was also adapted to the identifier in the container.

*Provider
All providers were moved from Inpsyde\GoogleTagManager\App\Provider to Inpsyde\GoogleTagManager\Provider

SiteInfoDataCollector

  • namespace from Inpsyde\GoogleTagManager\DataLayer\Site to Inpsyde\GoogleTagManager\DataLayer
  • identfier from DataLayer.Site.SiteInfoDataCollector to DataLayer.SiteInfoDataCollector.

UserDataCollector

  • namespace from Inpsyde\GoogleTagManager\DataLayer\User to Inpsyde\GoogleTagManager\DataLayer
  • identfier from DataLayer.User.UserDataCollector to DataLayer.UserDataCollector.

Upgrade of chrico/wp-fields

Additionally we now support chrico/wp-fields version 2, which also removes pimple/pimple, inpsyde/validator and inpsyde/filter as dependency.

PHP min version

The PHP min support was raised fro 7.2 to 8.0.

QoL

  • php-qa.yml // ad lint-php and coding-standards via inpsyde/reusable-workflows.
  • assets-compiler // update GA and configuration to make use of wordpress/scripts.
  • package.json // add "license", "keywords", "homepage" and "bugs".

1.6.2

09 Jun 11:21
77f4943
Compare
Choose a tag to compare
  • NoscriptTagRenderer // escape noscript URL
  • Update pre-compile-assets.yml
  • Update webpack.config.js
  • package.json // upgrade to node 16

1.6.1

11 May 10:55
Compare
Choose a tag to compare

Removes additional '>' bracket which was printed after the GTM ID due to a typo.

1.6.1

Pre-compiled assets available in assets-1.6.1.zip.

1.6

11 May 06:38
31f5132
Compare
Choose a tag to compare
1.6

New Features

  • DataLayerRendererEvent // rename constant for FILTER_SCRIPT_ATTRIBUTES.
  • Introduce new PrintInlineScriptTrait. Update DataLayerRenderer and GtmScriptTagRenderer to make use of trait.
  • GtmScriptTagRenderer // implemented new wp_print_inline_script_tag() function and fallback. allowing now to filter $script and $attributes.

Improvements

  • update to php >= 7.2 min. update to PHPUnit 8
  • Add composer.scripts for phpcs and phpunit. Add codecov to Github Action.

1.5

27 Apr 11:29
96d2b75
Compare
Choose a tag to compare
1.5

Improvements

Make use of wp_body_open which was introduced with WordPress 5.2.0, instead of hacking into body_class for rendering the <noscript> tag after <body> opened.

Hacking into body_class and closing the class attribute early did not work anymore since WordPress 5.5 where esc_attr was added.

1.4.0

12 Apr 07:52
f931e62
Compare
Choose a tag to compare

Updated

  • Updated inpsyde/assets to version ~2.5
  • Updated inpsyde/php-coding-standards to version 1.0.0-RC1.
  • Update most of the codebase to follow the updated standards
  • Update dependencies to support composer 2

1.3.1

05 Mar 08:31
4cd9c7e
Compare
Choose a tag to compare

composer.json // change psr/container to ~1.0 because of php-fig/container#27