public static function createView(
        string $actionName,
        ?string $ctrlName = null
    ): ?View {
        $viewsRoot = AppHelper::getInstance()->getComponentRoot('views');
        $addPath   = '';
        if (!empty($ctrlName)) {
            $addPath .= \DIRECTORY_SEPARATOR.strtolower($ctrlName);
        }
        $viewFile = $viewsRoot.$addPath.\DIRECTORY_SEPARATOR
            .strtolower($actionName).'.php';
        if (is_readable($viewFile)) {
            return new View($viewFile);
        }
        return null;
    }