inversify-page-request
v1.0.0
Published
page request util definitions
Readme
inversify-page-request
inversify page request utility
install dependencies
npm installbuild
npm run buildtest
npm testtest with coverage report
npm run test:coveragemutation test
npm run test:mutationformat
npm run formatInstall into project
npm install inversify-page-requestHow to use
Load the module.
...
import { PageRequestModule } from "inversify-page-request";
...
export const container = (): Container => {
const container = new Container();
container.load(new PageRequestModule());
return container;
};Inject the interface by type.
...
import { PAGE_REQUEST_TYPE, PageRequestMapperInterface } from "inversify-page-request";
...
@inject(PAGE_REQUEST_TYPE.PageRequestMapper)
private readonly pageRequestMapper: PageRequestMapperInterfaceUse the mapper.
...
const requestModel = pageRequestMapper.mapper(requestDto);
...
