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

container option in options doesn't work #12

Closed
amcdnl opened this issue Jul 12, 2016 · 3 comments
Closed

container option in options doesn't work #12

amcdnl opened this issue Jul 12, 2016 · 3 comments

Comments

@amcdnl
Copy link

amcdnl commented Jul 12, 2016

The container option in useExpressErver function does not work. See below.

import { useExpressServer, useContainer } from 'routing-controllers';
import { Container } from 'typedi';

function setup(app)
    const controllersPath = path.resolve('dist', 'controllers');

    useExpressServer(app, {
      controllerDirs: [ controllersPath ],
      options: { container: Container } // < Does not work
    });

    useContainer(Container); // Works
}
@pleerock
Copy link
Contributor

pleerock commented Jul 13, 2016

It should be like this:

 {
      controllerDirs: [ controllersPath ],
      container: Container
};

@amcdnl
Copy link
Author

amcdnl commented Jul 13, 2016

  • facepalm * - yes that works

@amcdnl amcdnl closed this as completed Jul 13, 2016
@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

2 participants