laravel-ide-helper icon indicating copy to clipboard operation
laravel-ide-helper copied to clipboard

add topclaudy/compoships support

Open alruhmi opened this issue 2 years ago • 1 comments

Summary

support topclaudy/compoships by adding check in method ModelsCommand::isRelationNullable().

Type of change

  • [ ] Bug fix (non-breaking change which fixes an issue)
  • [x] New feature (non-breaking change which adds functionality)
  • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • [ ] This change requires a documentation update
  • [ ] Misc. change (internal, infrastructure, maintenance, etc.)

Checklist

  • [ ] Existing tests have been adapted and/or new tests have been added
  • [ ] Add a CHANGELOG.md entry
  • [ ] Update the README.md
  • [ ] Code style has been fixed via composer fix-style

alruhmi avatar Feb 25 '22 09:02 alruhmi

Is there a way to avoid having this directly in the library? Like, using hooks or making the code more open/extendable so this can be maintained outside?

Why?

It's already not easy to handle all the variants you can with models just with laravel and multiple versions and on top of that supporting 3rd, no matter how popular, won't make it easier and it's prune to break stuff. Also it makes the code harder to reason for things barely used.

mfn avatar Feb 27 '22 20:02 mfn