Having recently started learning Vue.js, I am currently encountering difficulty with a seemingly simple task.
My goal is to add a Vuetify button to my webpage that allows users to download a file. However, I am struggling with getting the href
attribute to work properly. The file intended for download is stored in the /assets directory.
<v-btn
class="ma-2"
outlined
href="../assets/file.pdf"
target="_blank">
Download PDF
</v-btn>
Whenever I click on the button, it redirects me to a new URL which does not display the expected content:
http://localhost:8080/assets/file.pdf
The same issue persists even when I try moving the file to the /public directory.
I would greatly appreciate any assistance or guidance on this matter.