Ensuring that bar graphs are cleared before redrawing
This commit is contained in:
@@ -37,6 +37,9 @@ const width = 600; //+svg.attr("width");
|
||||
const height = 200; //+svg.attr("height");
|
||||
const margin = { top: 40, right: 30, bottom: 60, left: 30 };
|
||||
|
||||
//First clean the svg:
|
||||
svg.selectAll("*").remove();
|
||||
|
||||
// Draw the white background
|
||||
// Draw the rounded rectangle
|
||||
svg.append("rect")
|
||||
|
||||
Reference in New Issue
Block a user