Replies: 1 comment 1 reply
-
|
Hey @123niel, in general all additional attributes are forwarded so you can add any valid additional HTML attributes. So to implement a download button, you can just use: <OnyxButton
label="Download"
:link="{ href: '/my-file.png', target: '_blank' }"
download="downloaded-file-name"
/>The |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hey, the native anchor element has a
download-Property to indicate that the browser should download the content instead of display it: https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/download.It would be great to have this property in the Onyx components Link and Button.
Beta Was this translation helpful? Give feedback.
All reactions