Open ahmadkhalaf1 opened 6 years ago
Hi Ahmad,
After checking our code, there are two things:
First, internally, our SDK is based on Angular 1 and use Jquery as a helper. So to work, you need to load Jquery as a dependency.
Regarding events, currently, if you are not building an Angular 1 application, you need Jquery to listen to the events because internally, we use the method $(document).trigger(
Due to a bug in JQuery that has never been fixed (https://bugs.jquery.com/ticket/11047), it is not possible to listen to Jquery events without Jquery. document.addEventListener(...) method is not able to catch Jquery event.
CustomEvent could be an alternative but we need to see how to introduce it without breaking change or with limited breaking change.
Hope this will help to understand why JQuery has to be used.
Thank you for the explanation 👍
Hello ,
as i can see that jquery is used inside sdk.ts file . since we are using angular2 why do we need jquery and using it inside this file ?