All Downloads are FREE. Search and download functionalities are using the official Maven repository.

typescript-inversify.ApiServiceBinder.mustache Maven / Gradle / Ivy

There is a newer version: 7.7.0
Show newest version
import {interfaces} from 'inversify';

{{#apiInfo}}
{{#apis}}
import { {{classname}} } from './{{importPath}}';
{{#withInterfaces}}
import { {{classname}}Interface }  from './{{importPath}}Interface';
{{/withInterfaces}}
{{/apis}}
{{/apiInfo}}

export class ApiServiceBinder {
    public static with(container: interfaces.Container) {
        {{#apiInfo}}
        {{#apis}}
        container.bind<{{classname}}{{#withInterfaces}}Interface{{/withInterfaces}}>('{{classname}}').to({{classname}}).inSingletonScope();
        {{/apis}}
        {{/apiInfo}}
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy