Returns a version of func which that is bound to hub, and therefore does not need to specify the hub to use.
Arguments passed to func.
Return type of func.
The Hub instance to which this function will be bound.
The function to be bound.
const hub = new Hub();latest(hub, callback, 'test', 100);// With withHub:const waiter = withHub(hub, latest);waiter(callback, 'test', 100); Copy
const hub = new Hub();latest(hub, callback, 'test', 100);// With withHub:const waiter = withHub(hub, latest);waiter(callback, 'test', 100);
Returns a version of func which that is bound to hub, and therefore does not need to specify the hub to use.