Dependencies: component.json and package.json appear to conflict
Dependencies: component.json and package.json appear to conflict
![qdw](https://secure.gravatar.com/avatar/5f32cfea04a2b857655d6967a037312e/?default=https%3A%2F%2Fvanillicon.com%2F5f32cfea04a2b857655d6967a037312e_200.png&rating=g&size=120)
I think I've found a bug in the declaration of dependencies.
In the DataTables-1.9.4.zip distribution, component.json reads
"dependencies": {
"jquery": "~1.8.0"
}
which means you must use 1.8.x (see the spec at http://plugins.jquery.com/docs/package-manifest/ and search for "Tilde Version Ranges").
However, package.json reads
"dependencies": {
"jquery": "1.4 - 1.8"
},
which allows a much wider range of jQuery versions.
Is this indeed a bug? If so, which dependency spec is the correct one?
Thanks!
In the DataTables-1.9.4.zip distribution, component.json reads
"dependencies": {
"jquery": "~1.8.0"
}
which means you must use 1.8.x (see the spec at http://plugins.jquery.com/docs/package-manifest/ and search for "Tilde Version Ranges").
However, package.json reads
"dependencies": {
"jquery": "1.4 - 1.8"
},
which allows a much wider range of jQuery versions.
Is this indeed a bug? If so, which dependency spec is the correct one?
Thanks!
This discussion has been closed.
Replies
I've also renamed component.json to bower.json which uses that versioning as well.
Regards,
Allan.
If you want to say "1.8 and up," I think the best way to do it is "jquery": ">=1.8.0". I'm not sure whether "query": ">=1.7" means "1.7.0 and up" or "major versions greater than 1.7" (i.e., 1.8 and up). The spec at http://plugins.jquery.com/docs/package-manifest/ seems ambiguous on that point, and I don't see anything at http://semver.org/ that makes it clear. In any case, I think "jquery": ">=1.8.0" is clearer to a human reader.
Does that make sense? I'm not an expert; I'm just going by what that spec says.
Thanks,
Quinn
Allan