From 69dea07559f4eb5f03b05116f2e8a574917b61dd Mon Sep 17 00:00:00 2001 From: Shuhei Aoyama Date: Wed, 12 Sep 2018 10:57:53 +0900 Subject: [PATCH] fix(index.js): fix state initialization --- src/index.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/index.js b/src/index.js index 60e9b1a74..2b506abcd 100644 --- a/src/index.js +++ b/src/index.js @@ -74,7 +74,8 @@ class ReactTooltip extends React.Component { constructor (props) { super(props) this.state = { - place: 'top', // Direction of tooltip + place: props.place || 'top', // Direction of tooltip + desiredPlace: props.place || 'top', type: 'dark', // Color theme of tooltip effect: 'float', // float or fixed show: false,