Skip to content

条形码

HiBarcode 是一个生成条形码的组件。支持下载条形码图片。

image

安装方式

bash
yarn add pangea-ui

引用方式

js
import HiBarcode from "pangea-ui/hi-barcode";
import "pangea-ui/dist/style.css";

Props

参数名描述类型默认值
value条形码编码内容string
height尺寸 (条形码高度)string, number100
download是否显示下载按钮booleanfalse
displayValue条形码下方是否展示生成的内容booleantrue
id条形码容器 idstring

使用示例

html
<template>
  <HiBarcode
    content="hello"
    :download="true"
    :size="150"
    :displayValue="true"
  />
</template>