oauth-io / oauth-phonegap

OAuth.io plugin for Apache Cordova/PhoneGap
195 stars 69 forks source link

Insertion of jQuery without my knowledge #25

Closed ptbrowne closed 8 years ago

ptbrowne commented 10 years ago

Hello,

When OAuth does not find jQuery, it tries to be clever and inserts jQuery. The problem is that I use Zepto so I would prefer if it would check for $, fails if it does not find window.$ and fails hard instead of doing the magic of inserting a script tag with code.jquery.com/jquery-2.11.1.js . Moreover, since it is on mobile, we cannot rely on the network being there when the user opens the application.

What do you think ?

william26 commented 10 years ago

Hello,

Thanks for your feedback. The dependency on jQuery can indeed be problematic in some situations, like your own in that case.

We might remove this dependency altogether in a future version, but it's not in the immediate roadmap, as it would require major changes in the API. However, I believe that removing the auto tag insertion and letting the SDK fail if jQuery is absent would be possible in a near future release.

We'll keep you updated on this, Hope that helps :)

ptbrowne commented 10 years ago

Thanks for your quick response ! It helps :)

On Mon, Jun 30, 2014 at 11:53 PM, Antoine Jackson notifications@github.com wrote:

Hello,

Thanks for your feedback. The dependency on jQuery can indeed be problematic in some situations, like your own in that case.

We might remove this dependency altogether in a future version, but it's not in the immediate roadmap, as it would require major changes in the API. However, I believe that removing the auto tag insertion and letting the SDK fail if jQuery is absent would be possible in a near future release.

We'll keep you updated on this, Hope that helps :)

— Reply to this email directly or view it on GitHub https://github.com/oauth-io/oauth-phonegap/issues/25#issuecomment-47592325 .

bumpmann commented 8 years ago

jquery is included with a lightweighted compilation to include $ ajax in a closure so it's now light and won't pollute the other code.