typeioc

Home > typeioc > IWithSubstituteResult > intercept

IWithSubstituteResult.intercept property

Create a subject with members substituted by given parameters. For the instances of an object - interceptInstance method is used, for prototypical/constructible functions - interceptPrototype is used

Signature:

intercept: <R extends (Function | Object)>(subject: R) => R;