Has anyone successfully integrated the tracking.js library into a vueJS application?
I followed these steps to install the package:
npm install --save tracking
After that, I defined the library in my main.js file like this:
import tracking from 'tracking'
Object.defineProperty(Vue.prototype, '$tracking', { value: tracking });
In my component, I attempted to use the library with the following code:
mounted() {
var tracker = new this.$tracking.ObjectTracker('webcam');
}
However, when I run it, I get the error message:
TypeError: this.$tracking.ObjectTracker is not a constructor