From f5a3d8854d0cdd116d1dc65635c259808a41a885 Mon Sep 17 00:00:00 2001 From: silverwind Date: Fri, 23 Aug 2019 06:27:58 +0200 Subject: [PATCH] fix: React warning related to "true" used as boolean (via #5497) This should fix this warning seen in the console when using `swagger-ui-react`: ``` Warning: Received the string `true` for the boolean attribute `readOnly`. Although this works, it will not work as expected if you pass the string "false". Did you mean readOnly={true}? in textarea (created by Curl) in div (created by Curl) in div (created by Curl) in Curl (created by LiveResponse) in div (created by LiveResponse) in LiveResponse (created by Responses) ``` I did not test this change because it's trivial and there is no behavioural change here, React treats non-empty string attributes as `true`. --- src/core/components/curl.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/components/curl.jsx b/src/core/components/curl.jsx index ad1a2df4..b7a6f3e0 100644 --- a/src/core/components/curl.jsx +++ b/src/core/components/curl.jsx @@ -20,7 +20,7 @@ export default class Curl extends React.Component {

Curl

- +
)