2017 © Pedro Peláez
 

library styler

CSS Styler package for Laravel. Compiles Less/SCSS on the fly and supports serving cached content.

image

darren-nolan/styler

CSS Styler package for Laravel. Compiles Less/SCSS on the fly and supports serving cached content.

  • Monday, January 27, 2014
  • by darrennolan
  • Repository
  • 1 Watchers
  • 0 Stars
  • 23 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 4 Versions
  • 0 % Grown

The README.md

Styler

CSS Styler package for Laravel. Compiles Less/SCSS on the fly and supports serving cached content., (*1)

I wrote this particular package because I wanted something stupidly simple, and didn't want to 'watch' directories while I'm coding. Just recompile if the css has changed thanks., (*2)

Installing

To grab via composer, just add darren-nolan/styler on dev-master to your required packages., (*3)

"require": {
    "darren-nolan/styler": "0.0.2"
}

Features

  • SCSS and Less Compiling (Thanks to Leafo's SCSS and Less compilers.)
  • Raw CSS
  • Automatically switch between compilers based on file extension
  • Adjustable route to deliver the CSS

Setup

Firstly add the ServiceProvider to your app.php configuration, (*4)

'DarrenNolan\Styler\StylerServiceProvider',

Push the configuration into your application and edit as required (under app/config/packages/darren-nolan/styler/config.php), (*5)

php artisan config:publish darren-nolan/styler

base_route defines the listening base URL. By default <your-app>/styler/*.(css|less|scss) is where you link for compiled styles., (*6)

compiler defines the compiler/driver to use to compile stylesheets with. By default auto will check against the file's extension and compile accordingly., (*7)

Compiler options, (*8)

serve_from defines where this compiler should look for it's source files. By default app_path() . '/css' is used., (*9)

cache_folder defines where this compiler should store it's cached versions (if any). This folder should be created before use. Can be set to false to disable., (*10)

Special Compiler Options, (*11)

less has format_option which is what the output should be compiled as. 'lessjs', 'compressed', 'classic' and null are valid. Check documentation, (*12)

scss has format_option which is what the output should be compiled as. 'scss_formatter', 'scss_formatter_nested', and 'scss_formatter_compressed' are valid. Check documentation, (*13)

The configuration file is fairly self explanatory. However hang on for some better documentation., (*14)

Coming at some point

  • Tests. Because tests are important.
  • Each compiler is handed it's driver configuration in an array, however auto needs to get SCSS/LESS configuration too, so this will be adjusted so that a driver gets access to all configuration.
  • Code cleanup. Because I've been at a buck's all weekend and in my current capacity, I'm sure this is messy as hell.

License

Styler is open-source software licensed under the MIT license, (*15)

The Versions

27/01 2014

dev-master

9999999-dev

CSS Styler package for Laravel. Compiles Less/SCSS on the fly and supports serving cached content.

  Sources   Download

MIT

The Requires

 

laravel css less scss styles stylesheets

27/01 2014

dev-develop

dev-develop

CSS Styler package for Laravel. Compiles Less/SCSS on the fly and supports serving cached content.

  Sources   Download

MIT

The Requires

 

laravel css less scss styles stylesheets

27/01 2014

v0.0.2

0.0.2.0

CSS Styler package for Laravel. Compiles Less/SCSS on the fly and supports serving cached content.

  Sources   Download

MIT

The Requires

 

laravel css less scss styles stylesheets

28/09 2013

v0.0.1

0.0.1.0

CSS Styler package for Laravel. Compiles Less/SCSS on the fly and supports serving cached content.

  Sources   Download

MIT

The Requires

 

laravel css less scss styles stylesheets