angular.js icon indicating copy to clipboard operation
angular.js copied to clipboard

Use jqLite even if jQuery is present.

Open cmichal opened this issue 12 years ago • 8 comments

With rewritten and faster jqLite in angular 1.3 I would like to use it no matter if I have jQuery in my project or not. Can it be configurable in .run() function?

cmichal avatar Oct 23 '14 21:10 cmichal

why include jQuery at all if you're not going to use it?

caitp avatar Oct 23 '14 21:10 caitp

but maybe we can look at making this configurable using the same machinery as strict-di

caitp avatar Oct 23 '14 21:10 caitp

I need to use it for bunch of legacy plugins - we just wrap them as directives. I know that we could rewrite them, but why bother if they are already there?

cmichal avatar Oct 23 '14 21:10 cmichal

:+1:

Would be great to see config option, to use jQuery or not.

miraage avatar Oct 24 '14 07:10 miraage

Can't you just load angular before jquery?

jbedard avatar Oct 24 '14 08:10 jbedard

according to those comments:

    jqLite,           // delay binding since jQuery could be loaded after us.
    jQuery,           // delay binding

I assume it waits until everything is loaded.

cmichal avatar Oct 24 '14 08:10 cmichal

Further discussion in this PR: https://github.com/angular/angular.js/pull/2163

Narretz avatar Oct 24 '14 08:10 Narretz

There's more discussion in this older issue, let's keep the discussion centralized here: https://github.com/angular/angular.js/issues/608

Narretz avatar Oct 24 '14 09:10 Narretz