| Total Complexity | 3 |
| Total Lines | 22 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 9 | class QrCodeExtension extends AbstractExtension |
||
| 10 | { |
||
| 11 | private $renderer; |
||
| 12 | |||
| 13 | /** |
||
| 14 | * @return mixed |
||
| 15 | */ |
||
| 16 | public function getFunctions() |
||
| 17 | { |
||
| 18 | return [ |
||
| 19 | new TwigFunction('qr_code', [$this, 'qrCode']) |
||
| 20 | ]; |
||
| 21 | } |
||
| 22 | |||
| 23 | public function setRenderer(RendererInterface $renderer): void |
||
| 26 | } |
||
| 27 | |||
| 28 | public function qrCode(string $url, int $size = 100, int $margin = 10): string |
||
| 31 | } |
||
| 32 | } |
||
| 33 |