SOURCE

function funDecorator(target, name, descriptor) {
    let originalMethod = descriptor.value
    descriptor.value = function () {
        console.log('装饰器')
        return originalMethod.apply(this, arguments)
    }
    return descriptor
}
console 命令行工具 X clear

                    
>
console