我是TS新手...
我有以下代码:我想注释掉徽标。我尝试添加“ //”和“ / *”,但似乎无济于事。
对此进行了尝试:// <LogoComponent classes={{container: style.logoContainer, svg: style.logoSvg}} />
任何想法
export const HomePageComponent: React.StatelessComponent<HomePageProps> = (props) => {
return (
<div className={style.container}>
**COMMENT THIS LINE OUT ?**
<LogoComponent classes={{container: style.logoContainer, svg: style.logoSvg}} />
<div className={style.main}>
<CaptionComponent />
<SearchInput
searchValue={props.searchValue}
onSearchSubmit={props.onSearchSubmit}
onSearchUpdate={props.onSearchUpdate}
/>
<SearchButton onClick={props.onSearchSubmit}/>
</div>
<FooterComponent className={style.footer} />
</div>
)
答案 0 :(得分:0)
尝试这种方式
{ /*<LogoComponent classes={{container: style.logoContainer, svg: style.logoSvg}} /> */ }