php-barcode-generator
php-barcode-generator copied to clipboard
Feature Request - Add Attributes variable to SvgRenderer, etc.
Just a recommendation:
We need an ID attribute added to the SVG html output for javascript purposes, but it's not currently supported.
It would be nice to have an "attributes" variable passed to the "render" method of SVG/HTML generation in files like "Picqer\Barcode\Renderers\SvgRenderer", so that we can define our own attributes, example:
<svg id="random_id"/>
The only way to do so is to override the "render" method ourselves. However, that method does like 80 things though! So it will easily break any future updates you make if we do so. It might be further helpful to break up that code into their own methods that can be overridden to give more control over the render process.
Just my 2 cents. Thank you for your hard work in creating this excellent library.