/** * Allow a user to pass custom datas to * the metabox main view. * * @param string|array $key * @param mixed $value * @return \Themosis\Metabox\MetaboxBuilder */ public function with($key, $value = null) { $this->view->with($key, $value); return $this; }
/** * Run the composer events for a specific view. * * @param View $view * @return void */ public function callComposer(View $view) { $hook = 'composing: ' . $view->getName(); if ($this->action->exists($hook)) { do_action($hook, $view); } }