56

I see from here https://github.com/jquery/jquery-ui that jquery-ui's latest release is 1.11.4. However, when I use "npm install jquery-ui", it's only 1.10.3. I checked this version in node_modules/jquery-ui/jquery-ui.js.

Is there any way for me to install the latest version?

4
  • Check this, how to use version! Commented Dec 11, 2015 at 8:29
  • I tried npm install jquery-ui@latest, but I still have 1.10.3 Commented Dec 11, 2015 at 8:38
  • Sorry, I just realized I'm asking a stupid question. Node is using a different repository... not git... I'm not sure how I should deal this question now. Commented Dec 11, 2015 at 8:48
  • 4
    As per jquery-ui website, 1.12 is the first version officially released to npm: jqueryui.com/upgrade-guide/1.12/#official-package-on-npm If you are willing to skip 1.11.* then you can use this package: npmjs.com/package/jquery-ui Commented Oct 4, 2016 at 4:50

4 Answers 4

138

jQuery-ui specifically needs to be build after installation. To avoid this, use npm install jquery-ui-dist

Sign up to request clarification or add additional context in comments.

4 Comments

So, that package is maintained by you? Is there any connection to the jQuery team?
After jquery-ui 1.12 its possible to use the official package. See jqueryui.com/upgrade-guide/1.12/#official-package-on-npm
I don't get why the jQuery package has a dist folder, but the jQuery UI package does not and there is instead a separate package for the distributable. Very inconsistent.
Or do a npm install jquery-ui-dist --save to get installed a a dependency.
17

T J gave the right answer, but it is a bit short / too generic.

The GitHub project is at https://github.com/jquery/jquery-ui/

So the real command would be npm install github:jquery/jquery-ui (you can even skip github: as npm defaults to it).

But this would bring you the latest, unstable version (around 1.12 at time of writing), and it didn't even work when I tried.

So it is better to fetch a tagged version:

npm install github:jquery/jquery-ui#1.11.4

Generic note: AFAIK, if the project hasn't a package.json file, this kind of install can still fail.

3 Comments

This worked for me, getting and saving 1.12.0. Is there a way of checking if npm's version is outdated from the actual git source?
@BenSewards In general, I go to the NPM registry to see what version is listed (beware: several NPM entries can refer to the same GitHub project! I saw that with Angular UI Bootstrap, for example). Then I go to the GitHub project (referenced from the NPM page) and see the released versions (tagged). Some projects have no released version, alas.
@BenSewards: That's easy. npm install $packagename. As long as you leave off the "-S", it doesn't do any saving, and should output something like: "└── [email protected]"
6

Here is the current latest version (1.11.4), same package that bower is using, including all themes.

npm install github:components/jqueryui#1.11.4

Comments

0

You can install it like

npm install github:mygithubuser/myproject

as mentioned in the install documentation

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.