introduce the bar code library JsBarcode into Vue to report an error Encoder is not a constructor
code is as follows:
import JsBarcode from "jsbarcode";
mounted(){
this.$store.dispatch("actions_printSF",this.$route.params.shippingId).then(res=>{
this.form = res.data;
this.arrMoun = this.form.waybillno;
JsBarcode("-sharpbarcode", this.arrMoun)
})
},
< H2 > html < / H2 >
<img id="barcode"/>