1.3.0 • Published 4 years ago

@inventage/matomo-opt-out v1.3.0

Weekly downloads
12
License
MIT
Repository
github
Last release
4 years ago

\

A web component to let visitors opt-out of Matomo tracking.

made with open-wc Build Published on npm

Dependencies

Your Matomo installation will have to have the Ajax Opt Out plugin enabled.

Usage

import '@inventage/matomo-opt-out';
<matomo-opt-out matomo-url="https://analytics.your-domain.com"></matomo-opt-out>

Note on browser compatibility & transformation

Currently, the recommended way to publish a web component using open-wc is to publish the ES6/7 source code as is. Since your application knows best about which browsers to support and how to transform the source code (if at all) for those browsers, you will have to take care of any transformations yourself.

Properties

PropertyAttributeTypeDefault
isBusybooleanfalse
isTrackedbooleanfalse
matomoUrlmatomo-urlstring
optedInLabelopted-in-labelstring"You are not opted out. Uncheck this box to opt-out."
optedOutLabelopted-out-labelstring"You are currently opted out. Check this box to opt-in."

Development

  • Create a copy of local.config-example.js and name it local.config.js
  • Add the URL to your Matomo installation
  • Run $ npm start
  • Navigate to http://localhost:8000/demo/