【发布时间】:2021-01-28 00:22:59
【问题描述】:
【问题讨论】:
-
请不要发布你的代码截图,而是创建实际代码sn-ps为minimal, reproducible examples
-
不管怎样,按照React Router Documentation,你可以使用
<Link to={{ pathname: "/courses", search: "?sort=name", hash: "#the-hash", state: { fromDashboard: true } }} />;在你的情况下,你只需要设置pathname和hash -
谢谢,但我仍然不确定如何设置。我进入一个新页面,但我没有得到任何输出。
标签: javascript reactjs routes linker jsx