def before(name, context = proc {}, *args, &block)
      name = format('%s_%s', 'before_', name.to_s).to_sym

      if block_given?
        @hooks.append(name, block)

        self
      else
        @hooks.execute(name, context, *args)
      end
    end
def before(name, context = proc {}, *args, &block)
      name = format('%s_%s', 'before_', name.to_s).to_sym

      if block_given?
        @hooks.append(name, block)

        self
      else
        @hooks.execute(name, context, *args)
      end
    end
Define or run before-hook

 @param [Symbol, String] name
   The name of the hook

 @param [Proc] context
   The context a hook should run in. This is a runtime only option.

 @param [Array] args
   Arguments for the run of hook. This is a runtime only option.

 @yield
   The code block which should be run. This is a configure time only option