Link element in ReactRouter comes with "to" property which can have href, query object and hash inside.
I prefer to build a query from an object instead of using string templates.
// desired api
// <Link to={{href?: string, query?: object, hash?: string}}>
// desired input
<Link to={{href: "home", query: {key: "value"}, hash: "hash"}}><a>text</a></Link>
// desired output
<a href="/home?key=value#hash">text</a>