PHPackages                             alpin11/twig-barcode - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Templating &amp; Views](/categories/templating)
4. /
5. alpin11/twig-barcode

ActiveLibrary[Templating &amp; Views](/categories/templating)

alpin11/twig-barcode
====================

Symfony Bundle to generate barcodes within Twig

v1.2(4y ago)02213PHPCI failing

Since Oct 8Pushed 4y agoCompare

[ Source](https://github.com/alpin11/twig-barcode)[ Packagist](https://packagist.org/packages/alpin11/twig-barcode)[ RSS](/packages/alpin11-twig-barcode/feed)WikiDiscussions master Synced 2w ago

READMEChangelog (3)Dependencies (3)Versions (4)Used By (0)

Twig Barcode
============

[](#twig-barcode)

Generate barcodes within twig

Installation
------------

[](#installation)

Install through [composer](https://getcomposer.org/doc/00-intro.md):

```
composer require alpin11/twig-barcode
```

If you want to generate PNG or JPG images, you need the GD library or Imagick installed on your system as well.

### Usage

[](#usage)

Simply use it like any other Twig function:

```
barcode_html_ean13(theBarcodeValue, widthFactor = 2, totalHeight = 30)
```

### Options

[](#options)

#### Width Factor

[](#width-factor)

With that option you can manipulate the width of the barcode. Default is `2`. That means, the generated width of the barcode will be multiplied with you width factor.

### Total Height

[](#total-height)

With that option you can set the height of the generated barcode. The default is value is `30`

### Supported Formats

[](#supported-formats)

#### HTML

[](#html)

```
barcode_html_*
```

#### SVG

[](#svg)

```
barcode_svg_*
```

#### PNG

[](#png)

```
barcode_png_*
```

#### JPG

[](#jpg)

```
barcode_jpg_*
```

### Supported Types

[](#supported-types)

TypeTwig FunctionTYPE\_CODE\_39`barcode_*_c39`TYPE\_CODE\_39\_CHECKSUM`barcode_*_c39_plus`TYPE\_CODE\_39E`barcode_*_c39e`TYPE\_CODE\_39E\_CHECKSUM`barcode_*_c39e_plus`TYPE\_CODE\_93`barcode_*_c93`TYPE\_STANDARD\_2\_5`barcode_*_s25`TYPE\_STANDARD\_2\_5\_CHECKSUM`barcode_*_s25_plus`TYPE\_INTERLEAVED\_2\_5`barcode_*_i25`TYPE\_INTERLEAVED\_2\_5\_CHECKSUM`barcode_*_i25_plus`

###  Health Score

28

—

LowBetter than 52% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~354 days

Total

3

Last Release

1748d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/030c2d1619e640448247b08443490f72492b38e1e9b3f2cbc3257c4dc4641375?d=identicon)[davidhoeck](/maintainers/davidhoeck)

---

Top Contributors

[![dlhck](https://avatars.githubusercontent.com/u/24294584?v=4)](https://github.com/dlhck "dlhck (1 commits)")

---

Tags

symfony-bundlesymfony3symfony4twig

### Embed Badge

![Health badge](/badges/alpin11-twig-barcode/health.svg)

```
[![Health](https://phpackages.com/badges/alpin11-twig-barcode/health.svg)](https://phpackages.com/packages/alpin11-twig-barcode)
```

###  Alternatives

[craftcms/cms

Craft CMS

3.6k3.6M2.9k](/packages/craftcms-cms)[abydahana/aksara

Aksara is a CodeIgniter based CRUD Toolkit you can use to build complex applications become shorter, secure and more reliable just in a few lines of code. Serving both CMS or Framework, produce both HEADLESS (RESTful API) or TRADITIONAL (Browser Based), just by writing single controller. Yet it's reusable, scalable and ready to use!

1111.2k](/packages/abydahana-aksara)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
