From 8b13f341b61e7972264b1125914732a857c36cdc Mon Sep 17 00:00:00 2001 From: Alex Liebowitz Date: Tue, 22 Nov 2016 00:24:29 -0500 Subject: [PATCH] Don't render hidden form fields --- js/component/form.js | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/js/component/form.js b/js/component/form.js index 8bc9ecc78..70cb3beb0 100644 --- a/js/component/form.js +++ b/js/component/form.js @@ -62,13 +62,15 @@ var FormField = React.createClass({ delete otherProps.hidden; return ( -
- - {this.props.children} - - {this.state.adviceText} -
+ !this.props.hidden + ?
+ + {this.props.children} + + {this.state.adviceText} +
+ : null ); } });