0.1.0 • Published 4 years ago

mustdi v0.1.0

Weekly downloads
1
License
MIT
Repository
github
Last release
4 years ago

mustdi


Best IoC Container for Js ever!!! WIth package system Main idea to use comments as meta information about types in classes See example with expressjs application.

As simple as container.getBean('BestBeanEver'):

const Di = require('mustdi');

/**
 * ExpressTestApplication class
 */
class ExpressTestApplication {
  /**
   * Main method as main in java ;)
   * With Js and mustdi nothing is impossible
   */
  static main() {
    const container = new Di.DefaultContainer(__dirname, [
      './app/*.bean.js',
      './controllers/*.ctrl.js',
      './db-adapters/*.db.js',
      './models/*.model.js',
      './routers/*.router.js',
      './config/*.config.js',
      './loggers/*.logger.js',
    ]);
    container.getBean('Server').start();
  }
}

if (module === require.main) {
  ExpressTestApplication.main();
}

Sponsors

ScalableSpace and ScaleChamp

0.1.0

4 years ago

2.0.1

7 years ago

2.0.0

7 years ago

0.0.9

7 years ago

0.0.8

7 years ago

0.0.6

7 years ago

1.0.5

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago