x4js - v2.3.33
    Preparing search index...

    Function renderBarcodeImage

    • A barcode as an image, for the screen: "data:image/svg+xml,...", for the src of an Image or an Icon. Drawn on white, with its quiet zone (1 module around a Data Matrix, 10 on the sides of a Code 128): it can be read on a dark theme too. A Code 128 is 50 modules high.

      Parameters

      Returns string

      new Image( { src: renderBarcodeImage( "datamatrix", "G1234K7" ) } )
      new Image( { src: renderBarcodeImage( "code128", "(01)03400930000120(17)270101", { gs1: true, module: 2 } ) } )