New to Kendo UI for Vue? Start a free 30-day trial

Barcode

Component

Represents the Kendo UI for Vue Barcode component. Accepts properties of type BarcodeProps.

Definition

Package:@progress/kendo-vue-barcodes

Properties Interface:BarcodeProps

Syntax:

vue
<Barcode
    :type="'EAN13'"
    :value="'590123412345'"
    :width="300"
    :height="120"
    :render-as="'svg'"
/>

Properties

Sets the background color of the Barcode. Accepts any valid CSS color string, such as hex and rgb values.

Default:

"white"

Sets the border of the Barcode. Accepts an object of type Border.

checksum?

boolean

Shows or hides the checksum digit next to the value in the text area.

Default:

false

color?

string

Sets the color of the Barcode. Accepts any valid CSS color string, such as hex and rgb values.

Default:

"black"

Exports the Barcode as an image. Accepts optional export settings and returns a Promise that resolves with the image data string.

Parameters:options?ImageExportOptionsReturns:

Promise​<string>

Exports the Barcode as an SVG document. Accepts optional export settings and returns a Promise that resolves with the SVG data string.

Parameters:options?SVGExportOptionsReturns:

Promise​<string>

height?

number

Sets the height of the Barcode in pixels. You can also set the size of the Barcode with CSS.

Sets the padding of the Barcode. Accepts a number or an object of type Padding.

Default:

0

Sets the rendering engine of the component.

The possible values are:

  • "svg"—Renders the component as an inline svg element, if the browser supports it.
  • "canvas"—Renders the component as a canvas element, if the browser supports it.
Default:

'svg'

Sets the text label of the Barcode. Accepts an object of type BarcodeText.

type?

string

Sets the symbology (encoding) of the Barcode. Accepts a BarcodeType value or a custom string.

Default:

"Code39"

value?

string | number

Sets the value of the Barcode. Accepts a string or a number.

width?

number

Sets the width of the Barcode in pixels. You can also set the size of the Barcode with CSS.