If I put a single or multiline comment inside a <View>
enclosure throws an error Trying to add unknown view tag:
and what looks like an array map of the tags.
Also found that if I use a multiline comment, the interpreter still renders the commented out elements
Such as
/*
<View>
<Image source={require('image!bg_splash')} style={{}} />
</View>
*/
I still received unknown module 'image!bg_splash'
during my last issue #2808
This is how JSX works (independent of React Native). JSX does not support comments - you need to push them in to JS, ex: {/* comment */}
Got it. Thank you.
Just curious, does this create any performance overhead?
Most helpful comment
This is how JSX works (independent of React Native). JSX does not support comments - you need to push them in to JS, ex:
{/* comment */}