-
Notifications
You must be signed in to change notification settings - Fork 7
Open
Description
In order to use server with scssphp 2.0.1 I had to add one line to omit the utf-bom (because that was placed after the "/* compiled by scssphp 2.0.1 on Mon, ...") and one line to set the importPaths (because that has to be implicitely set now).
My code is now:
<?php
require_once './vendor/autoload.php';
use ScssPhp\ScssPhp\Compiler;
use ScssPhp\ScssPhp\OutputStyle;
use ScssPhp\Server\Server;
$scssDirectory = 'scss';
$scssCompiler = new Compiler();
$scssCompiler->setCharset(false);
$scssCompiler->setOutputStyle(OutputStyle::COMPRESSED);
$scssCompiler->setImportPaths($scssDirectory);
new Server($scssDirectory, null, $scssCompiler)
->serve();
One could add defaults for those two in the __construct of Server.php to make it work nicely again with scssphp 2.0.1 and real easy to use.
I'm willing to make a pull request.
Metadata
Metadata
Assignees
Labels
No labels