hey guys. since the jquery support in stdlib is de...
# javascript
d
hey guys. since the jquery support in stdlib is deprecated, is there any good way to use jquery in kotlinJS? or what’s the best practice to trigger for example animations like fadeIn? just executing raw JS via
js(...)
seems a bit too much for that
g
You can use the dynamic type, or create an interface labelled with the external keyword for the methods you need
d
thanks. so far i’ve created custom methods and used the
external
keyword (can i use external keyword directly on JQuery methods instead of my custom implemented ones?). what do you mean with dynamic type?
g
From those, you can see how I am importing external modules in Communicator.kt and Vue.kt then external global functions in Common.kt
I also have external interfaces to represent the modules I'm importing, those interfaces are just a representation of the object that im importing so that I can use the methods I need from it
you can see how im using the dynamic type on the initial modules im importing so that then i can call any method or property i want from it
you can do the same with jquery
d
ah i see. thanks. dynamic looks like what I’m trying to achieve 👍