From 1ad95f9c36de70d3149caf11ca8c90cd8491aacc Mon Sep 17 00:00:00 2001 From: Aaron Lampros Date: Fri, 18 Oct 2019 16:34:46 -0400 Subject: [PATCH] fix: use componentDidUpdate instead Fix #73 --- src/ReactConfetti.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ReactConfetti.tsx b/src/ReactConfetti.tsx index 69d2d02..4d3921e 100644 --- a/src/ReactConfetti.tsx +++ b/src/ReactConfetti.tsx @@ -30,7 +30,7 @@ class ReactConfettiInternal extends Component { } } - getSnapshotBeforeUpdate() { + componentDidUpdate() { const confettiOptions = extractCanvasProps(this.props)[0] if(this.confetti) { this.confetti.options = confettiOptions as IConfettiOptions