@@ -11,7 +11,7 @@ description: You can use shallow routing to change the URL without triggering a
...
@@ -11,7 +11,7 @@ description: You can use shallow routing to change the URL without triggering a
</ul>
</ul>
</details>
</details>
Shallow routing allows you to change the URL without running [`getInitialProps`](/docs/api-reference/data-fetching/getInitialProps.md).
Shallow routing allows you to change the URL without running data fetching methods again, that includes [`getServerSideProps`](/docs/basic-features/data-fetching.md#getserversideprops-server-side-rendering), [`getStaticProps`](/docs/basic-features/data-fetching.md#getstaticprops-static-generation), and [`getInitialProps`](/docs/api-reference/data-fetching/getInitialProps.md).
You'll receive the updated `pathname` and the `query` via the [`router` object](/docs/api-reference/next/router.md#router-object)(added by [`useRouter`](/docs/api-reference/next/router.md#useRouter) or [`withRouter`](/docs/api-reference/next/router.md#withRouter)), without losing state.
You'll receive the updated `pathname` and the `query` via the [`router` object](/docs/api-reference/next/router.md#router-object)(added by [`useRouter`](/docs/api-reference/next/router.md#useRouter) or [`withRouter`](/docs/api-reference/next/router.md#withRouter)), without losing state.
...
@@ -68,4 +68,4 @@ Shallow routing **only** works for same page URL changes. For example, let's ass
...
@@ -68,4 +68,4 @@ Shallow routing **only** works for same page URL changes. For example, let's ass