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

Investigate: Investigate a good DI for CoMPAS utilities #221

Open
pascalwilbrink opened this issue Feb 16, 2023 · 8 comments
Open

Investigate: Investigate a good DI for CoMPAS utilities #221

pascalwilbrink opened this issue Feb 16, 2023 · 8 comments
Labels

Comments

@pascalwilbrink
Copy link
Member

For Utilities used in CoMPAS (http-communication, etc), It would be useful to have a good Dependency Injection mechanism (like TypeDI / Inversify)

For Http-like communication, it would be nice to have some globally defined interceptors (for for example error-handling)

@pascalwilbrink
Copy link
Member Author

Npm Trends (https://npmtrends.com/awilix-vs-bottlejs-vs-inversify-vs-jimple-vs-node-dependency-injection-vs-typedi)
shows that Inversify / awilix / bottlejs is the best solution.

Name Stars Issues Version Updated Created
awilix 2,777 2 8.0.0 4 months ago 7 years ago
bottlejs 1,250 6 2.0.1 8 months ago 8 years ago
inversify 9,675 265 6.0.1 a year ago 8 years ago

@pascalwilbrink
Copy link
Member Author

The Configurating mixing will be obsolete when this is implemented. Configuration can be injected

@Sander3003
Copy link
Member

Good work! @AliouDIAITE can you add the people this ticket who like to get involved?

@pascalwilbrink
Copy link
Member Author

Small POC with Inversify as a Dependency Injection framework
https://stackblitz.com/edit/typescript-ap8zgw

@AliouDIAITE
Copy link
Member

Good work! @AliouDIAITE can you add the people this ticket who like to get involved?

@samirromdhani is interested!

@Sander3003
Copy link
Member

If this is needed, depends on the result of this discussion: https://github.com/openscd/open-scd/discussions/1190

@samirromdhani
Copy link

Good work! @AliouDIAITE can you add the people this ticket who like to get involved?

@samirromdhani is interested!

This POC uses injection-js, a tool coming from an Angular background which means that it's well designed, feature complete, fast, well tested and it's easy to write.
https://stackblitz.com/edit/js-dependency-injection

@github-actions
Copy link

Hello there,

Thank you for opening this issue! We appreciate your interest in our project.
However, it seems that this issue hasn't had any activity for a while. To ensure that our issue tracker remains organized and efficient, we occasionally review and address stale issues.

If you believe this issue is still relevant and requires attention, please provide any additional context, updates, or details that might help us understand the problem better.
Feel free to continue the conversation here.

If the issue is no longer relevant, you can simply close it. If you're uncertain, you can always reopen it later.

Remember, our project thrives on community contributions, and your input matters. We're here to collaborate and improve.
Thank you for being part of this journey!

@github-actions github-actions bot added the stale label Oct 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants