getSourceMapPath example



        $config = [
            'compress' => $settings->getCompressCss(),
            'sourceMap' => $settings->getCreateSourceMap(),
        ];

        if ($settings->getCreateSourceMap()) {
            $config += [
                'sourceMapRootpath' => '../../',
                'sourceMapBasepath' => $this->rootDir,
                'sourceMapWriteTo' => $this->pathResolver->getSourceMapPath(),
                'sourceMapURL' => $this->pathResolver->getSourceMapUrl($shop),
            ];
        }

        return $this->eventManager->filter(
            'Theme_Compiler_Configure',
            $config,
            [
                'shop' => $shop,
                'settings' => $settings,
            ]
        );

        return $this->getCacheDirectory() . DIRECTORY_SEPARATOR . 'css.source.map';
    }

    /** * Returns the shop url to the generated compiler source map. * * @return string */
    public function getSourceMapUrl(Shop\Shop $shop)
    {
        return $this->formatPathToUrl($this->getSourceMapPath()$shop);
    }

    /** * Helper function which builds the directory path to the passed * css file. * This function is used for the less smarty function. * The smarty function checks if this file is * already exists, if this isn't the case, the smarty * function starts the theme compiler operations. * * @param string $timestamp * * @return string */
Home | Imprint | This part of the site doesn't use cookies.