/** {@inheritDoc} */
 public function register()
 {
     /** @var \Illuminate\Foundation\Application $app */
     $app = parent::register();
     $config = array_dot($this->app['config']['blade_extensions']);
     if ($config['example_views'] === true) {
         $this->viewDirs = ['views' => 'blade-ext'];
     }
     $this->registerHelpers();
     AssignmentDirectives::attach($app);
     DebugDirectives::attach($app);
     ForeachDirectives::attach($app);
     EmbeddingDirectives::attach($app);
     MacroDirectives::attach($app);
     MinifyDirectives::attach($app);
     # Optional markdown compiler, engines and directives
     if ($config['markdown.enabled']) {
         if (!class_exists($config['markdown.renderer'])) {
             throw new Exception('The configured markdown renderer class does not exist');
         }
         $app->bind('Radic\\BladeExtensions\\Contracts\\MarkdownRenderer', $config['markdown.renderer']);
         $app->singleton('markdown', function (Application $app) {
             return $app->make('Radic\\BladeExtensions\\Contracts\\MarkdownRenderer');
         });
         $app->singleton('markdown.compiler', function (Application $app) {
             $markdownRenderer = $app->make('markdown');
             $files = $app->make('files');
             $storagePath = $app['config']->get('view.compiled');
             return new MarkdownCompiler($markdownRenderer, $files, $storagePath);
         });
         MarkdownDirectives::attach($app);
     }
 }
 /**
  * {@inheritdoc}
  */
 public function register()
 {
     $app = parent::register();
     $this->codexRouteExclusion(config('codex.hooks.sassdoc.route_prefix'));
     $this->codexHook('factory:ready', FactoryHook::class);
     $this->codexHook('project:documents-menu', ProjectDocumentsMenuHook::class);
     $this->extendProject();
     $this->extendSassdocDocument();
 }
Ejemplo n.º 3
0
 /**
  * {@inheritdoc}
  */
 public function register()
 {
     $app = parent::register();
     $this->addRouteProjectNameExclusions('git-hook-webhook');
     // Add the hook which merges the codex config.
     $this->addCodexHook('factory:ready', FactoryHook::class);
     // And add the hook providing the  `gith` method for projects to retreive a gitsync instance for that specific project
     $this->addCodexHook('project:ready', ProjectHook::class);
 }
Ejemplo n.º 4
0
 /**
  * {@inheritdoc}
  */
 public function register()
 {
     $app = parent::register();
     $this->codexRouteExclusion('git-hook-webhook');
     // Add the hook which merges the codex config.
     $this->codexHook('factory:ready', FactoryHook::class);
     Project::extend('gitSyncer', function () {
         /** @var Project $this */
         return app('codex.hooks.git')->gitSyncer($this);
     });
 }
 /**
  * Register the service provider.
  *
  * @return void
  */
 public function register()
 {
     parent::register();
 }
Ejemplo n.º 6
0
 /**
  * Register bindings in the container.
  *
  * @return Application
  */
 public function register()
 {
     $app = parent::register();
     $this->registerLogger($app);
     $this->registerFilters();
 }
Ejemplo n.º 7
0
 /**
  * {@inheritdoc}
  */
 public function register()
 {
     $app = parent::register();
 }