Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactoring conditional usage of (commercial) packages #554

Open
adrolli opened this issue Jun 27, 2024 · 0 comments
Open

Refactoring conditional usage of (commercial) packages #554

adrolli opened this issue Jun 27, 2024 · 0 comments
Assignees

Comments

@adrolli
Copy link
Member

adrolli commented Jun 27, 2024

Using commercial packages like "Advanced Tables" should not be done by introducing a composer dependency. Instead, these packages should be loaded conditionally using class_exists or trait_exists. This is currently implemented in Moox Core, but comes with a couple of culprits:

  • Stan does not like it
  • Intelephense does not like it
  • Codacy does not like it
  • It will become pretty spaghetti, when multiple packages need to be coupled this way

Refactoring should be done by using one of following techniques:

  • DI container aka Service container
  • Abstraction to service classes

Currently, some features of Advanced Tables are disabled (in AdminPanelProvider of Intranet-project) to prevent user-facing errors:

  • Quick save
  • Preset views manageable
  • View manager search
  • Advanced Filter Builder
@adrolli adrolli self-assigned this Jun 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant