Skip to content

Commit 2cb29d5

Browse files
Linho1219mauriciopoppe
authored andcommitted
Add graphType to key
Add the graphType to the key to handle graphType updates on the same function. Fix #344.
1 parent 7596fe1 commit 2cb29d5

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/chart.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -553,7 +553,8 @@ export class Chart extends EventEmitter.EventEmitter {
553553
},
554554
(d: any) => {
555555
// The key is the function set or other value that uniquely identifies the datum.
556-
return d.fn || d.r || d.x || d.text
556+
// Fix #344: add graphType to the key to avoid update issues
557+
return JSON.stringify([d.fn || d.r || d.text || [d.x, d.y], d.graphType])
557558
}
558559
)
559560

0 commit comments

Comments
 (0)