PHP code example of pushinbr / pam-native-svg

1. Go to this page and download the library: Download pushinbr/pam-native-svg 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/ */

    

pushinbr / pam-native-svg example snippets




declare(strict_types=1);

use Pam\Native\Svg\{Svg, Path, ProgressRing, SvgAnimation, SvgProperty};

ProgressRing::make($upload->fraction)->size(44)->strokeWidth(3)->color('#ffffff');

Svg::fromFile(__DIR__.'/assets/send.svg')->tint('#1d9bf0')->size(24);

Svg::make(24, 24)
    ->add(Path::make('M5 12l5 5L19 7')->id('check')->fill('none')->stroke('#fff', 2)->pathLength(1)->trim(0, 0))
    ->animate(SvgAnimation::to('check', SvgProperty::TrimEnd, $done ? 1 : 0)->duration(260));
bash
pam tests/run.php                                  # PHP contracts
cd android && gradle -PpamPluginApi=/path/pam-native-android-plugin-api-1.39.2.aar \
  testDebugUnitTest connectedDebugAndroidTest      # JVM + emulator instrumentation