public function compile()
    {
        $templateFilePrefix = $this->hasLocalizedVersion() ?
            $this->generateLocalizedViewPath() :
            $this->generateDefaultViewPath();

        $content = self::parseFile(
            $templateFilePrefix . $this->getConfig('file_extention'),
            $this->contextualVariables,
            (bool)$this->getConfig('allow_debug')
        );

        if (is_null($this->getConfig("layout"))) {
            return $content;
        }

        $layout = self::parseFile(
            $this->generateDefaultLayoutPath() . $this->getConfig('file_extention'),
            $this->contextualVariables,
            (bool)$this->getConfig('allow_debug')
        );

        return str_replace(self::TPL_YIELD, $content, $layout);
    }