Errors are thrown when searching for the tw and css props on an element with text content, assuming those options are enabled. The text content will have props of whatever the content is, i.e., "This is Twind!". Can't use the in operator to search on a string.
Solution?
I'm not sure why that method is used to begin with ("tw" in props), but solution could be as simple as switching that to props.tw or just checking to ensure props is an object first. I don't have the background knowledge here, so you'll likely know better.
Reproduction
The CodeSandbox linked in the ReadMe reproduces the error. You'll be met by
cannot use 'in' operator to search for "tw" in "This is Twind!"
Explanation
Errors are thrown when searching for the
tw
andcss
props on an element with text content, assuming those options are enabled. The text content will haveprops
of whatever the content is, i.e.,"This is Twind!"
. Can't use thein
operator to search on a string.Solution?
I'm not sure why that method is used to begin with (
"tw" in props
), but solution could be as simple as switching that toprops.tw
or just checking to ensureprops
is an object first. I don't have the background knowledge here, so you'll likely know better.