For developers who used to the JQuery
for many years, we used to get the html element always.
I find it very tricky in angularjs
,
I'm looking for an equivalent of $(selector)
.
I'll give you an example where I need the HTML element.
I'm using select2
as my dropdown when i need to set the defualt value I need to run the following code:
$("#id").select2('data', { id: id, text: text });
because select2
angularjs
wrapper is not binding properly.
Or if anyone can help with maybe a different way of thinking.