Open thereddestdog opened 7 months ago
Here's some sample code for you:
// msg must be a certain length to generate 12x26, that length varies depending on character/number makeup
// rct indicates that you want a rectangle rather than a square
const options = {
msg : "Bacon is grand!",
rct : 1
};
// Generate the SVG
const svg = DATAMatrix(options);
// Append it to something
document.body.appendChild(svg);
You can also check out the Live Demo for real-time generation.
How could I generate a 12x26 2D barcode, for example?