Is it possible to remove jQuery?


#1

I’m using Meteor 1.3 beta 5 and React 0.14.6, so I don’t need jQuery, but I can’t figure out how to remove it, or which package depends on it.

Current list of installed packages:

  • meteor-base
  • mobile-experience
  • mongo
  • blaze-html-templates
  • standard-minifiers
  • es5-shim
  • ecmascript
  • fourseven:scss

Is it possible to remove it?


#2

Hi @babak1

From that list, I’m guessing blaze-html-templates is the culprit as blaze requires jQuery.

Although you can do it, it’s surprisingly difficult to get rid of jQuery as so many packages depend on it.

You can use this:

for p in `meteor list | grep '^[a-z]' | awk '{ print $1"@"$2 }'`; do echo "$p"; meteor show "$p" | grep -E '^  [a-z]'; echo; done

To list your packages’ dependencies (source: http://stackoverflow.com/questions/26153603/how-to-show-all-package-dependency-tree)

But it only lists immediate dependencies. So if blaze-html-templates relies on blaze it would show blaze but if blaze relies on jQuery it wouldn’t be listed. Still haven’t found a better way to get all dependencies - if anyone reading knows please share!


#3

I just run your script, but I haven’t seen jQuery in dependencies. Strange behavior here in Meteor beta :smile:
But on the page it still present


#4

This is how to remove/replace jQuery:


#5

MDG, if you’re letting us choose the frontend (React, Angular, Blaze), why are we stuck with jQuery?

Please work on removing this dependency.


#6

You may want to comment on this issue as more likely to get a response or make some progress on the issue.


#7

Hello everyone, I heard that now we can create an app without jquery (even without MongoDB)

Can someone point me to the way to make it ?