-
-
Notifications
You must be signed in to change notification settings - Fork 499
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Assets and routes #32
Comments
You cannot use "dynamic paths" that change at runtime because webpack evaluates them before. An easy solution for this is to move the images in the static folder and link to them with |
so for each image also we would need to check if the image exists otherwise get the "fallback" one. |
I try to bind my image src attribute and use a path that depends on the current locale:
<img :src="'~/assets/image-' + $i18n.locale + '.svg'">
However it does not work and the output is:
<img src="~/assets/image-en.svg">
Another issue is with video posters, my paths don't work. Any idea?
<video poster="~/assets/poster.png">...</video>
The text was updated successfully, but these errors were encountered: