# Link\_to vs button\_to with method post - different behaviour intended?

**URL:** <https://discuss.hotwired.dev/t/link-to-vs-button-to-with-method-post-different-behaviour-intended/2004>\
**Category:** General\
**Created:** [January 15, 2021, 12:25am UTC](https://discuss.hotwired.dev/t/link-to-vs-button-to-with-method-post-different-behaviour-intended/2004 "2021-01-15T00:25:06Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![koenhandekyn](https://yyz1.discourse-cdn.com/flex027/user_avatar/discuss.hotwired.dev/koenhandekyn/32/1071_2.png) [@koenhandekyn](https://discuss.hotwired.dev/u/koenhandekyn)\
**Post date:** [January 15, 2021, 12:25am UTC](https://discuss.hotwired.dev/t/link-to-vs-button-to-with-method-post-different-behaviour-intended/2004/1 "2021-01-15T00:25:06Z")

</div>

based on an online tutorial I have the following two lines in my view. rails/ujs is loaded, running rails 6.1.0 with latest version of turbo.

the button\_to gives the desired behaviour, the current frame is replaced with the corresponding frame from the response.

the link\_to has identical behaviour on the server side but results in the page being blanked out and only the corresponding frame to remain visible, which feels unexpected. is their some logic behind this I could try to understand?

```
<%= button_to "Like (#{tweet.likes})", tweet_like_path(tweet), method: :post %>
<%= link_to "Like (#{tweet.likes})", tweet_like_path(tweet), method: :post %>
```

---

<div class="post-metadata">

**Author:** ![augustocallejas](https://yyz1.discourse-cdn.com/flex027/user_avatar/discuss.hotwired.dev/augustocallejas/32/1472_2.png) [@augustocallejas](https://discuss.hotwired.dev/u/augustocallejas)\
**Post date:** [January 17, 2021, 7:54am UTC](https://discuss.hotwired.dev/t/link-to-vs-button-to-with-method-post-different-behaviour-intended/2004/2 "2021-01-17T07:54:48Z")

</div>

Sounds like this [issue](https://github.com/hotwired/turbo-rails/issues/52).
