nicohaase / twig-isbn-formatter
ISBN formatting extension for Twig
0.2
2020-03-29 17:11 UTC
Requires
- php: ^7.2
- nicebooks/isbn: ^0.2
- twig/twig: ^1.38|^2.0|^3.0
Requires (Dev)
- phpunit/phpunit: ^8.5
This package is auto-updated.
Last update: 2021-01-29 18:59:35 UTC
README
Based on nicebooks/isbn
, this tiny package provides two Twig filters such that ISBNs can be formatted simply.
Installation
Just run composer install nicohaase/twig-isbn-formatter
Available filters
formatIsbn
will add dashes where neccessarytoIsbn13
will provide a ISBN-13 out of any valid (ie. ISBN-10 or ISBN-13) input
Examples
{{"9783411040162"|formatIsbn}}
will output978-3-411-04016-2