library/Widget/Source/BaseWidget.php
public function widget($args, $instance)
    {
        $this->data['args'] = $args;
        $this->data['instance'] = $instance;

        if (method_exists($this, 'beforeViewController')) {
            $this->beforeViewController();
        }

        $this->viewController($args, $instance);

        if (method_exists($this, 'afterViewController')) {
            $this->afterViewController();
        }

        $blade = new Blade($this->viewPath, $this->cachePath);
        echo $blade->view()->make('widget.' . str_replace(array('widget.', '.blade.php'), '', $this->template), $this->data)->render();
    }
public function widget($args, $instance)
    {
        $this->data['args'] = $args;
        $this->data['instance'] = $instance;

        if (method_exists($this, 'beforeViewController')) {
            $this->beforeViewController();
        }

        $this->viewController($args, $instance);

        if (method_exists($this, 'afterViewController')) {
            $this->afterViewController();
        }

        $blade = new Blade($this->viewPath, $this->cachePath);
        echo $blade->view()->make('widget.' . str_replace(array('widget.', '.blade.php'), '', $this->template), $this->data)->render();
    }
public function widget ( $ args , $ instance ) { $ this -> data [ 'args' ] = $ args ; $ this -> data [ 'instance' ] = $ instance ; if ( method_exists ( $ this , 'beforeViewController' ) ) { $ this -> beforeViewController ( ) ; } $ this -> viewController ( $ args , $ instance ) ; if ( method_exists ( $ this , 'afterViewController' ) ) { $ this -> afterViewController ( ) ; } $ blade = new Blade ( $ this -> viewPath , $ this -> cachePath ) ; echo $ blade -> view ( ) -> make ( 'widget.' . str_replace ( array ( 'widget.' , '.blade.php' ) , '' , $ this -> template ) , $ this -> data ) -> render ( ) ; }
Front-end of the widget. Instantiates the viewController method and renders blade view.

@param array $args     Display arguments including 'before_title', 'after_title',
'before_widget', and 'after_widget'.

@param array $instance The settings for the particular instance of the widget.

@return void
Front - end of the widget . Instantiates the viewController method and renders blade view .