0

I have the following file:

bower.json

{   
  "name": "genesis",   
  "dependencies": {     
      "codemirror": "^5.18.2",     
      "ember": "^2.8.0",     
      "ember-cli-shims": "^0.1.3",     
      "ember-load-initializers": "^0.5.1",     
      "ember-qunit-builds": "^1.0.0-beta.1",     
      "ember-qunit-notifications": "^0.1.0",     
      "font-awesome": "^4.6.3",     
      "jquery-legacy": "jquery#^2", 
      "jquery-modern": "jquery#^3", 
      "jQuery-contextMenu": "^2.2.4",     
      "lato": "^0.3.0",     
      "lightbox2": "^2.8.2",     
      "loader.js": "^4.0.11",     
      "moment": "^2.14.1",     
      "mozilla-fira": "4.202",     
      "multiselect": "^0.9.12",     
      "qunit": "^2.0.1",     
      "selectize": "^0.12.3",     
      "semantic-ui": "^2.2.4"  
  } 
}

If I would do a bower list on this project I would get to see that all dependencies that depend on jQuery are 3.1.1, making one such package (lightbox2) incompatible.

[folatt@ArkOS_Dev genesis]$ bower list

genesis /home/folatt/workspace/arkos/genesis
├── codemirror#5.20.0
├─┬ ember#2.9.0 (2.10.0-beta.1 available)
│ └── jquery#3.1.1
...
├── jquery-migrate#3.0.0 extraneous
├── lato#0.3.0
├─┬ lightbox2#2.8.2
│ └── jquery#3.1.1 incompatible with ~2 (2.2.4 available, latest is 3.1.1)
...

Removing jquery-modern and bower list shows that all dependencies that depend on jQuery use 2.2.4.

What I would like to see is that all dependencies that depend on jQuery use 3.1.1, except for lightbox2, which should use 2.2.4.

Is that possible and if so, how?

Folaht
  • 1,053
  • 1
  • 13
  • 32
  • 1
    Instead of using 2 jQuery versions, try using jQuery migrate with version 3.1.1 to get access to deprecated functions. – Stephen C Oct 20 '16 at 12:55
  • 1
    You know that you have to [use noConflict](http://stackoverflow.com/questions/1566595/can-i-use-multiple-versions-of-jquery-on-the-same-page) if you want two versions of jquery on the same page, right? And this requires you to write code, i.e. bower can't do this for you – Liam Oct 20 '16 at 12:55
  • +stephen-c Isn't jquery-migrate for personal jquery code and not that of a dependency? – Folaht Oct 20 '16 at 17:31

1 Answers1

0

Problem solved by forking lightbox2 and forcing it to use jQuery 3.

Folaht
  • 1,053
  • 1
  • 13
  • 32