Skip to main content
Version: next

Custom Plugins

The analytics library is designed to work with any third party analytics tools via plugins, in this guide we will explore how to write and use custom plugins.

Plugins are a powerful abstraction that let you:

  • add a new analytics provider (like Google analytics or Meta pixel)
  • hook into an existing analytics provider plugin
  • or add any kind of logic to react to visitor actions

Plugins can be broken down into 2 types:

  • Provider plugins - connecting to third party analytic services
  • Custom plugins - additional features, data manipulation, & any other side effects.

Both have the same signature, and are registered in the same way, here we will explore how they are implemented within a Front-Commerce app.

info

You can look at the analytics library documentation to learn more about the plugin types.