New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make Matomo JS Tracker work in strict mode #14791
Comments
Hi, Quick question: How are you using |
Sure feel free to do a PR 👍 That should be fine to prefix it with |
I think this ticket should be closed as there is nothing to do - the JSON_PIWIK variable is long gone from the codebase: https://github.com/matomo-org/matomo/pull/15785/files |
It would still be great if someone could test if importing matomo.js as an npm package works correctly and if this was the only thing breaking it. |
Did a quick test and what was missing was still prefixing some variables with window which I fixed in #16498 |
* Make JS tracker work in strict mode fix #14791 * rebuilt piwik.js
as I am using es6 module and import piwik.js via npm package, every dependency are in js strict mode
It will show error
ReferenceError: JSON_PIWIK is not defined
Can we wrap all global variables with
window.
? It seems can fix the issue easily, I am ok to open PR to do itThe text was updated successfully, but these errors were encountered: