使用 react 的模块包:react-helmet
步骤:
- 安装:npm install react-helmet --save
- 引入:import { Helmet } from ‘react-helmet’;
- 代码中的使用
<Helmet>
<meta charSet="utf-8" />
<title>系统应用</title>
<link rel="canonical" href="https://blog.csdn.net/qq_24917475" />
</Helmet>