I'm writing an angular.js directive, which would conditionally hide the element. So it would look like this:
link: function(scope, elem, attrs) {
...
elem.hide()
}
I found a lot of examples that were doing exactly that, but somehow my elem attribute is an array not an element, so it does not have a hide() method. What am I missing?
Thanks!