Devise\Templates\TemplatesRepository::getTemplateByPath PHP Method

getTemplateByPath() public method

Get template and any related data by using its template path to retrieve its related data from the templates config
public getTemplateByPath ( string $templatePath ) : array
$templatePath string
return array
    public function getTemplateByPath($templatePath)
    {
        $configData = $this->Config->get('devise.templates');
        if (isset($configData[$templatePath])) {
            $template = $configData[$templatePath];
            $templateSource = $this->getTemplateSourceByPath($templatePath);
            // if extends is empty/not set, retrieve it from blade
            if (empty($template['extends'])) {
                $template['extends'] = $this->getTemplateExtends($templateSource);
            }
            // retrieve and set any vars found in source of config
            $template['vars'] = $this->getVarsFromSource($template, $templateSource);
            // split vars array into vars and newVars keys
            $template = $this->splitVarsAndNewVars($template);
            return $template;
        } else {
            throw new DeviseTemplateNotFoundException('"' . $templatePath . '" was not found in templates config. Please check the devise.templates.php and ensure this path exists.');
        }
    }