use() {
        const args = Array.from(arguments);
        
        let event = typeof args[0] === 'function' ? ANY_EVENT : args.shift(),
            callback = typeof args[0] === 'function' ? args.shift() : () => {};

        return this._stack.push({ event, callback });
    }
/**
     * Push a middleware to the stack
     * 
     * @author schroffl
     *
     * @param {String} [event=ANY_EVENT] - The specific event to listen for
     * @param {Function} callback - A function to be called on execution of the stack
     *
     * @returns The position of the middleware in the stack
     */
Push a middleware to the stack

@author schroffl

@param {String} [event=ANY_EVENT] - The specific event to listen for
@param {Function} callback - A function to be called on execution of the stack

@returns The position of the middleware in the stack
Push a middleware to the stack @author schroffl @param { String } [ event = ANY_EVENT ] - The specific event to listen for @param { Function } callback - A function to be called on execution of the stack @returns The position of the middleware in the stack
use() {
        const args = Array.from(arguments);
        let event = typeof args[0] === 'function' ? ANY_EVENT : args.shift(),
            callback = typeof args[0] === 'function' ? args.shift() : () => {};
        return this._stack.push({ event, callback });
    }
use ( ) { const args = Array . from ( arguments ) ; let event = typeof args [ 0 ] === 'function' ? ANY_EVENT : args . shift ( ) , callback = typeof args [ 0 ] === 'function' ? args . shift ( ) : ( ) => { } ; return this . _stack . push ( { event , callback } ) ; }
Push a middleware to the stack
Push a middleware to the stack