hashgraph / solo

An opinionated CLI tool to deploy and manage standalone test networks.
Apache License 2.0
26 stars 7 forks source link

Use Inversion of Control (IoC) container #37

Closed leninmehedy closed 2 weeks ago

leninmehedy commented 11 months ago

Use one of:

Need to do evaluation on the available frameworks.

instamenta commented 1 month ago

@jeromy-cannon

During my research, I found that the only library truly designed to support Vanilla JS is Awilix, because:

Given this, I’m wondering if we should consider migrating to TypeScript. Doing so will address the current issue with Inversion of Control (IoC), improve the developer experience (DevEx), and possibly attract more outside contributions. Additionally, this change will make the codebase more maintainable for the future and reveal current bugs that haven't been found yet.

IoC for TypeScript:

jeromy-cannon commented 1 month ago

@jeromy-cannon

During my research, I found that the only library truly designed to support Vanilla JS is Awilix, because:

  • It's the only one that's actively maintained.
  • It was specifically built for Vanilla JS.

Given this, I’m wondering if we should consider migrating to TypeScript. Doing so will address the current issue with Inversion of Control (IoC), improve the developer experience (DevEx), and possibly attract more outside contributions. Additionally, this change will make the codebase more maintainable for the future and reveal current bugs that haven't been found yet.

IoC for TypeScript:

@instamenta , I discussed this with @nathanklick , but we are not ready to move to TypeScript. We don't want to add the extra compiler layer. There is an upcoming version of NodeJS that allows TypeScript integration directly into NodeJS, however it is still early development and we want to keep our user base on the LTS version. So, at this point if there are no other options to consider, then we can move forward with Awilix

jeromy-cannon commented 2 weeks ago

being implemented in https://github.com/hashgraph/solo/issues/590