1.0.0 • Published 4 years ago

@feizheng/next-aop v1.0.0

Weekly downloads
1
License
MIT
Repository
-
Last release
4 years ago

next-aop

Aop for next.

installation

npm install -S @feizheng/next-aop

usage

import '@feizheng/next-aop';

console.log = nx.aop(console.log, {
  before: function (oldConsole) {
    oldConsole('=--before--=');
  },
  after: function (oldConsole) {
    oldConsole('=--after--=');
  },
});

// test:
console.log('---abc---');

// =--before--=
// ---abc---
// =--after--=
1.0.0

4 years ago