src/ShortcodesServiceProvider.php
public function registerView()
    {
        $finder = $this->app['view']->getFinder();

        $this->app->singleton('view', function ($app) use ($finder) {
            // Next we need to grab the engine resolver instance that will be used by the
            // environment. The resolver will be used by an environment to get each of
            // the various engine implementations such as plain PHP or Blade engine.
            $resolver = $app['view.engine.resolver'];
            $env = new Factory($resolver, $finder, $app['events'], $app['shortcode.compiler']);

            // We will also set the container instance on this view environment since the
            // view composers may be classes registered in the container, which allows
            // for great testable, flexible composers for the application developer.
            $env->setContainer($app);
            $env->share('app', $app);

            return $env;
        });
    }
public function registerView()
    {
        $finder = $this->app['view']->getFinder();

        $this->app->singleton('view', function ($app) use ($finder) {
            // Next we need to grab the engine resolver instance that will be used by the
            // environment. The resolver will be used by an environment to get each of
            // the various engine implementations such as plain PHP or Blade engine.
            $resolver = $app['view.engine.resolver'];
            $env = new Factory($resolver, $finder, $app['events'], $app['shortcode.compiler']);

            // We will also set the container instance on this view environment since the
            // view composers may be classes registered in the container, which allows
            // for great testable, flexible composers for the application developer.
            $env->setContainer($app);
            $env->share('app', $app);

            return $env;
        });
    }
public function registerView ( ) { $ finder = $ this -> app [ 'view' ] -> getFinder ( ) ; $ this -> app -> singleton ( 'view' , function ( $ app ) use ( $ finder ) { // Next we need to grab the engine resolver instance that will be used by the // environment. The resolver will be used by an environment to get each of // the various engine implementations such as plain PHP or Blade engine. $ resolver = $ app [ 'view.engine.resolver' ] ; $ env = new Factory ( $ resolver , $ finder , $ app [ 'events' ] , $ app [ 'shortcode.compiler' ] ) ; // We will also set the container instance on this view environment since the // view composers may be classes registered in the container, which allows // for great testable, flexible composers for the application developer. $ env -> setContainer ( $ app ) ; $ env -> share ( 'app' , $ app ) ; return $ env ; } ) ; }
Register Laravel view.
Register Laravel view .