The Difference Between a Button and a Link

(unplannedobsolescence.com)

20 points | by alexpetros 1 hour ago

5 comments

  • zhonglin 1 minute ago
    Is this too tech for hacker news? LOL
  • singpolyma3 40 minutes ago
    You can have button actions today by wrapping the button in a form tag. The article even shows this. The implication seems to be somehow that this is no good because what if you're already in a form tag? The answer is to move the two actions which aren't actually related to the form outside of the form tag and give them their own unique form parents.
  • TonyAlicea10 29 minutes ago
    > Buttons regularly perform navigations. Clicking a logout button navigates the current page to a logged-out one; clicking a “search” button navigates the current page to the query results.

    This seems to conflate appearance with semantics. If an element causes a navigation, I make it a link. Whether it looks like a button is irrelevant, that’s CSS.

    I always choose one or the other by intended behavior first, and that always works out great.

    That said, I like the idea.

  • wxw 34 minutes ago
    > The proposal itself is very straightforward: we want to add the action and method attributes to the button.

    Hell yea! Inching our way towards native HTMX.

  • greatsage_sh 16 minutes ago
    [flagged]