1

I’m using Rails 4.2.7. In my Gemfile, I have

gem 'rails', '~> 4.2.7'
…
gem 'jquery-ui-rails'

How do I figure out what version of JQuery UI I’m using?

ABN
  • 1,024
  • 13
  • 26
  • Per my comment to the other answer, that tells me the version of the Gem but that is different than the version of JQuery UI. I want to know the version of JQuery UI correspoding to the gem. –  Aug 19 '16 at 17:31
  • Google "what jquery version am i using" or see http://stackoverflow.com/questions/6973941/how-to-check-what-version-of-jquery-is-loaded or http://stackoverflow.com/questions/12423864/how-can-i-find-out-what-jquery-version-im-using-without-using-jquery or https://api.jquery.com/jquery-2/ – jvillian Aug 19 '16 at 17:34

3 Answers3

1
bundle show jquery-ui-rails

This command will show you which version of that gem is being used in your project. You can also inspect your Gemfile.lock file or type

bundle show

to display all the gems being used.

To see the version of the jquery-ui plugin being used by any website, you can open the console tab in the developers tools of your browser and then type:

$.ui
Hans Findel
  • 126
  • 4
  • That shows the version of the Gem, but not necessarily of JQuery-UI, right? The lock file says "jquery-ui-rails (5.0.5)" but there is no such thing as JQuery UI 5.0.5. My question was about jquery UI, not the gem per se. –  Aug 19 '16 at 17:30
  • That command will show you the gem version. The easiest way to inspect the version being used in a website is asking directly. Open your browsers inspector (in google chrome by inspect element with the option click or cmd+alt+i) and then selecting the console tab. There you type $.ui (and then enter) and you will be able to see the version of the jquery-ui – Hans Findel Aug 19 '16 at 17:46
1

You look in the file VERSIONS.md, in which you can see the following (top five lines):

5.0.5   1.11.4
5.0.4   1.11.3
5.0.3   1.11.2
5.0.2   1.11.2
5.0.1   1.11.1

From the JQuery UI Rails README file:

See VERSIONS.md to see which versions of jquery-ui-rails bundle which versions of jQuery UI.

MarsAtomic
  • 10,436
  • 5
  • 35
  • 56
0
  1. Use bundle show to know the version of jquery gem -

    bundle show jquery
    

    It will list something like -

    1 : jquery-rails
    2 : jquery-ui-rails
    3 : rails-jquery-autocomplete
    0 : - exit -
    
  2. Select the appropriate option. In my system on selection of 2(jquery-ui-rails) it displayed -

    .../jquery-ui-rails-6.0.1
    
  3. Check the gem to jquery version mapping @ https://github.com/jquery-ui-rails/jquery-ui-rails/blob/master/VERSIONS.md . In my case it was

    Gem      jQuery UI
    6.0.1    1.12.1
    

Note: I have combined @Hans Findel and @MarsAtomic answer.

ABN
  • 1,024
  • 13
  • 26