1. Go to this page and download the library: Download luizbills/css-generator library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
luizbills / css-generator example snippets
use luizbills\CSS_Generator\Generator as CSS_Generator;
$options = [
// default values
// 'indent_style' => 'space', // you can change to 'tab'
// 'indent_size' => 4 // 4 spaces by default
];
$css = new CSS_Generator( $options );
// define your css code (see below)
// output the generated code
echo "<style>" . $css->get_output() . "</style>";
$css->open_block( 'media', 'screen and (min-width: 30em)' );
$css->add_rule( 'a', [ 'color' => 'red' ] );
$css->close_block(); // close the last opened block