Remove jQuery dependency
jadrake75 opened this issue · 3 comments
For the most part jQuery is being used for selectors. While it is not the end of the world, it would be nice to not have to have a jQuery dependency on the library
A quick and easy fix for this would be to replace the follow regex searches:
$((.+?))
and
jQuery((.+?))
with
document[0].body.querySelector($1)
My understand though is that querySelector does not support 100% of the
selectors used by jQuery. We are also using attr( ) if memory serves and
some of the addClass/removeClass methods. Again nothing that can not be
done easily in HTML-5 evergreen browsers using modern JS but still some
effort to do it. I think it starts with an assessment of where the impacts
are and how to address them.
On Mon, Jan 5, 2015 at 1:30 PM, Xanir notifications@github.com wrote:
A quick and easy fix for this would be to replace the follow regex
searches:$((.+?))
and
jQuery((.+?))with
document[0].body.querySelector($1)—
Reply to this email directly or view it on GitHub
#81 (comment)
.
Correct that querySelector does not support all jQuery selectors but it does support all CSS selectors.
angular.element, without jQuery installed also supports addClass/removeClass and the attr function.