MCPcopy
hub / github.com/mobxjs/mobx / wrapFunction

Function wrapFunction

packages/mobx-react/src/utils/utils.ts:118–123  ·  view source on GitHub ↗
(realMethod: Function, mixins: Mixins)

Source from the content-addressed store, hash-verified

116}
117
118function wrapFunction(realMethod: Function, mixins: Mixins): (...args: Array<any>) => any {
119 const fn = function (...args: Array<any>) {
120 wrapper.call(this, realMethod, mixins, ...args)
121 }
122 return fn
123}
124
125export function patch(target: object, methodName: string, mixinMethod: Function): void {
126 const mixins = getMixins(target, methodName)

Callers 1

createDefinitionFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected