We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi, I have successfully created the canvas. Now, I want to clear this canvas with the click of a button.
<div id="bar_code"> <Barcode renderer="canvas" value={"test"} font="trebuchet ms" height={50} /><br/> </div>
on click of button, I am trying the code below,
var bar_cnv = document.getElementById('bar_code').firstChild; var ctx2 = bar_cnv.getContext('2d'); ctx2.clearRect(0, 0, bar_cnv.width, bar_cnv.height);
But the canvas is not getting cleared. Any help will be appreciated.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Hi,
I have successfully created the canvas.
Now, I want to clear this canvas with the click of a button.
on click of button, I am trying the code below,
But the canvas is not getting cleared.
Any help will be appreciated.
The text was updated successfully, but these errors were encountered: