Closure

clonefunction

Creates and returns a new function with the exact same behaviour as fn.

Syntax

clonefunction(fn: function): function