PHP code example of oncology-support / sparkline-bundle

1. Go to this page and download the library: Download oncology-support/sparkline-bundle 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/ */

    

oncology-support / sparkline-bundle example snippets


// config/bundles.php

return [
    // ...
    OncologySupport\Sparkline\OncologySupportSparklineBundle::class => ['all' => true],
];

// your twig template

{{ sparkline(<array of data>)|raw }}

// your twig template

{{ sparkline([2,3,10,8,23,14,9,12,0,0,14])|raw }}