nestjs-esewa
Version:
This is simple wrapper for Esewa Payment extended from @dallotech/nestjs-esewa. It supports Epay-V2 and transaction verification for Esewa SDK, but later more will be added. Just ping us or open pull request and contribute :)
23 lines (21 loc) • 705 B
text/typescript
import {DynamicModule, Module} from '@nestjs/common';
import EsewaAsyncOptions, {ESEWA_CONFIG_OPTIONS} from "./esewa.interface";
import {EsewaService} from "./esewa.service";
import {HttpModule} from "@nestjs/axios";
({})
export class EsewaModule {
static registerAsync(options: EsewaAsyncOptions): DynamicModule {
return {
module: EsewaModule,
imports: [HttpModule, ...options.imports],
providers: [{
provide: ESEWA_CONFIG_OPTIONS,
useFactory: options.useFactory,
inject: options.inject
},
EsewaService
],
exports: [EsewaService]
}
}
}