ailon / markerjs-live

Display dynamic, interactive, and scalable image annotations in your web apps.
7 stars 1 forks source link

No method on MarkerView to add license key #3

Closed stefan-sl closed 2 years ago

stefan-sl commented 2 years ago

Hi, if I'm using markerjs2 the MarkerArea class has a method addLicenseKey(). If I'm using markerjs-live no corresponding method exists on MarkerView. So I have to import Activator and call addKey directly on that before opening the MarkerView.

Activator.addKey("MY_KEY"); const markerViewer = new MarkerView(targetElement);

I don't know if this is intentional or not but to me it seems like the two libraries should have similar ways of adding keys.

ailon commented 2 years ago

Hi @stefan-sl,

Activator.addKey() is the official way.

The instance method is just a convenience proxy method that just calls Activator... It was added to markerjs2 at some point (probably in response to someone's request, can't remember now).

P.S.: In the future, please email info@markerjs.com for license-related questions.