angular-threejs / angular-three

Angular Renderer for THREE.js
MIT License
184 stars 23 forks source link

NPM package peer dependencies #19

Closed nicorac closed 1 month ago

nicorac commented 1 year ago

I had a lot of issues installing this package (required by a third-party component...) because of the strict versions declared as peer dependencies in package.

Example: it requires @angular/router: "16.0.0", but I actually have 16.0.3 installed...

It forced me to use the --legacy-peer-deps npm option to complete the installation.

  "peerDependencies": {
    "@angular/common": "^15.1.0 || ^16.0.0",
    "@angular/core": "^15.1.0 || 16.0.0",
    "three": "^0.148.0 || ^0.149.0 || ^0.150.0 || ^0.151.0 || ^0.152.0",
    "rxjs": "7.8.0",
    "@angular/router": "16.0.0"
  },

IMHO it should read like this (added ^ prefix to @angular/core, rxjs and @angular/router versions):

  "peerDependencies": {
    "@angular/common": "^15.1.0 || ^16.0.0",
    "@angular/core": "^15.1.0 || ^16.0.0",
    "three": "^0.148.0 || ^0.149.0 || ^0.150.0 || ^0.151.0 || ^0.152.0",
    "rxjs": "^7.8.0",
    "@angular/router": "^16.0.0"
  },
SKaDiZZ commented 1 year ago

I'm, having the same issue hope you'll find time to fix it because using --force or --legacy-peer-deps isn't exactly a solution

nicorac commented 1 year ago

Is anyone taking care of this? I could open a PR for it... but I see there's one waiting till 2023-05-19 🤔...

nicorac commented 1 month ago

Can't wait for #35 to complete then...😉 Keep up the good work!