React Router 6.3.0
Is there a way to be able to pass state and query params in same navigate call, and have both applied?
Steps to Reproduce
Try
navigate( { pathname: "/search", search: `?${createSearchParams({ query: someQuery })}`, state: { someAttributeName: someAttributeValue } } );
Note that the query params are passed in the URL but state will be null.
Try
navigate( "/search", { search: `?${createSearchParams({query: someQuery})}`, state: { someAttributeName: someAttributeValue } } );
Note that the state is passed but the query params are not applied.