@malagu/core
Version:
13 lines • 633 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.Aspect = void 0;
const aop_protocol_1 = require("../aop/aop-protocol");
const component_1 = require("./component");
const Aspect = (adviceOrAspectOption) => (target) => {
const option = component_1.parseComponentOption(target, adviceOrAspectOption);
option.pointcut = option.pointcut || component_1.COMPONENT_TAG;
option.tag = { tag: aop_protocol_1.AOP_TAG, value: option.pointcut };
component_1.applyComponentDecorator(Object.assign({ proxy: false }, option), target);
};
exports.Aspect = Aspect;
//# sourceMappingURL=aspect.js.map