From 9db8d54def17c53ceedb3108adf5d07c3d8efedf Mon Sep 17 00:00:00 2001 From: Ali Taheri Date: Tue, 29 Dec 2015 23:12:53 +0330 Subject: [PATCH] Avoid rendering element This has caused many issues, when an element is created in this component there will be no way to support links, as nested elements is offensive in the eyes of HTML. Closes #2178, #1979, #1823 --- src/enhanced-button.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/enhanced-button.jsx b/src/enhanced-button.jsx index 93ab00d8414ba7..9f5fa672023ce5 100644 --- a/src/enhanced-button.jsx +++ b/src/enhanced-button.jsx @@ -197,7 +197,7 @@ const EnhancedButton = React.createClass({ return React.isValidElement(containerElement) ? React.cloneElement(containerElement, buttonProps, buttonChildren) : - React.createElement(linkButton ? 'a' : containerElement, buttonProps, buttonChildren); + React.createElement(linkButton ? 'span' : containerElement, buttonProps, buttonChildren); },