@nestjs/swagger
Version:
Nest - modern, fast, powerful node.js web framework (@swagger)
13 lines (12 loc) • 529 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
const lodash_1 = require("lodash");
const constants_1 = require("../constants");
const helpers_1 = require("./helpers");
const defaultOperationOptions = {
summary: ''
};
function ApiOperation(options) {
return helpers_1.createMethodDecorator(constants_1.DECORATORS.API_OPERATION, lodash_1.pickBy(Object.assign(Object.assign({}, defaultOperationOptions), options), lodash_1.negate(lodash_1.isUndefined)));
}
exports.ApiOperation = ApiOperation;