A Better Form for UBT

Matomo Tag Manager

πŸ“‹ Agenda

  • Current Situation
  • Matomo Tag Manager (MTM)
  • MTM Concepts
  • Demo
  • Conculsion

πŸ˜• Current Situation

  • Lengthy process for UBT modifications
    1. Ask frontend
    2. Modify Tag in codebase
    3. Commit
    4. Push
    5. PR
  • Different codes for Piwik & Pendo
  • UBT Tags separated in different files

πŸ€” What if?

  • Modify UBT without changing frontend codebase

Β 

  • One effort for both Piwik & Pendo

Β 

  • Manage all UBTs Tags from a place

Matomo Tag Manager (MTM)

  • Matomo's (formerly Piwik) Tag Management System (TMS)
    • Control UBTs from Matomo's console
    • Since v3.7.0

MTM Concepts - Components

  • 🏷 Tag
    • A snippet of code which can be executed on your site
    • e.g. send UBT object, Custom HTMLs
  • πŸ’₯ Trigger
    • Conditions that let you define on which event a tag should be fired.
    • e.g. Clicked, Scroll
  • πŸ”€ Variables
    • Dynamic value which will be resolved at the time the value is being accessed
    • e.g. Current URL, Current Scroll Position, Current CSS Class...etc

MTM Concepts - Components

  • πŸ’Ύ Data Layer
    • Indent for accessing data which are not on UI
    • e.g. vid, language​
  • πŸ“¦ Container
    • Stores all these components

Components - To illustrateΒ 

{
    category: 'Favorite Button',
    action: Clicked_{{Favorite Count}},
    name: '',
    value: ''
}

πŸ’₯ Trigger

🏷 Tag

πŸ”€ Variables /

πŸ’Ύ Data Layer

πŸ“¦ Container

MTM Concepts - Publish

  • πŸ‘ Preview / Debug
  • ⬆️ Publish
  • 🎞 Version Control

MTM Concepts - Add UBT Process

Pre-request: Insert πŸ“¦ Container Code

🏷

Add a Tag

πŸ’₯

Link to a Trigger

πŸ‘

Preview / Debug

⬆️ 

Publish

🎞  Version added

πŸ‘πŸ½ Pros

  • AgilityΒ 
  • Better Management for Tags
  • Version control

πŸ‘ŽπŸ½ Cons

  • Still need to change codebase when
    • use custom variables
    • send different event with one trigger

Conclusion

Thanks for listening!

Matomo Tag Manager

By Chang Henry

Matomo Tag Manager

  • 46