ember-data-model-fragments icon indicating copy to clipboard operation
ember-data-model-fragments copied to clipboard

Ember-data version compatibility

Open ctjhoa opened this issue 8 years ago • 3 comments

Hi, I run through compatibility issue with the latest version of ember data (2.11.0) and I would like to know if there no other solution than the compatibility table existing in the README.md.

I know that some other ember-addon like ember-modal-dialog handle ember compatibility in their package.json.

Is there no way to write something similar for ember-data-model-fragments? E.g. for the ember-data-model-fragments v2.3.x it could be something like:

  "ember-addon": {
    "versionCompatibility": {
      "ember-data": ">= 2.3.0 < 2.11.0"
    }
  }

With this, if I'm right, ember install ember-data-model-fragments will lead to the installation of the right version of the addon whatever your version of ember-data is.

PS: I cannot find any documentation on this versionCompatibility it's only supposition

ctjhoa avatar Jan 25 '17 08:01 ctjhoa

To be honest, I'm not really much of an NPM expert. I think one option would be if this addon moved the ember-data dependency from devDependencies to dependencies and that would force conflict resolution in during npm install. But it doesn't seem like very many, if any, ember addons do this. It seems they keep ember in the devDependencies and I'm not sure if there is a specific reason for that.

I would absolutely accept a PR for adding versionCompatibility to the package.json file.

workmanw avatar Jan 26 '17 12:01 workmanw

Actually I saw this PR come through. https://github.com/jamesarosen/ember-i18n/pull/433/files It seems very relevant here. I'll investigate this in the near future when I have time.

workmanw avatar Jan 28 '17 13:01 workmanw

@workmanw moving to dependencies would cause a very odd set of bugs because you'd get the merge of the two instead of resolving one or the other.

versionCompatibility is definitely something I'd recommend.

runspired avatar May 02 '18 05:05 runspired