Commit 84493a67 authored by Jimmy Moon's avatar Jimmy Moon Committed by Tim Neutkens

Update readme.md (#3957)

Update readme for scroll props related to #3950
parent dac6e9c1
...@@ -429,6 +429,15 @@ export default ({ href, name }) => ...@@ -429,6 +429,15 @@ export default ({ href, name }) =>
</Link> </Link>
``` ```
##### Disabling the scroll changes to top on page
The default behaviour of `<Link>` is to scroll to the top of the page. When there is a hash defined it will scroll to the specific id, just like a normal `<a>` tag. To prevent scrolling to the top / hash `scroll={false}` can be added to `<Link>`:
```jsx
<Link scroll={false} href="/?counter=10"><a>Disables scrolling</a></Link>
<Link href="/?counter=10"><a>Changes with scrolling to top</a></Link>
```
#### Imperatively #### Imperatively
<p><details> <p><details>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment