How antd card components support Rich text title?

problem description

the title attribute of the Card component of antD ( https://ant.design/components.), which, according to the documentation, supports not only the string type, but also the reactNode type.

document:

title = "Card title =" string | ReactNode

Code

<Card bordered={false}
      title={title} // 
      className={classNames.join(" ")}
      style={cardStyle}>
      <div>{content}</div>
</Card>

expectation

ask the great god, how to support rich text title? through ReactNode form (for example, < span class="style" > title )

Aug.13,2021

const  reactNode = () => <span className='style'>title</span>;
<Card bordered={false}
      title={reactNode()} // 
      className={classNames.join(' ')}
      style={cardStyle}>
      <div>{content}</div>
</Card>

or:

<Card bordered={false}
      title={React.createElement('span', {className:'style'}, title)} // 
      className={classNames.join(' ')}
      style={cardStyle}>
      <div>{content}</div>
</Card>

dangerouslySetInnerHTML , you can convert string to dom

<Card title={<div dangerouslySetInnerHTML={{__html: "<span class='style'>title</span>"}}></div>}></Card>
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e46bfc-44367.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e46bfc-44367.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?