Skip to content
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

@vue/server-renderer renderToString generating incorrect srcset URL for source elements within a router link #3536

Closed
lukewarlow opened this issue Apr 2, 2021 · 1 comment
Labels
🔨 p3-minor-bug Priority 3: this fixes a bug, but is an edge case that only affects very specific usage. 🐞 bug Something isn't working

Comments

@lukewarlow
Copy link

Version

3.0.11

Reproduction link

https://github.com/lukewarlow/vue-server-render-bug

Steps to reproduce

Clone the git repository. Run npm install and then npm run generate. This will generate a dist/static/index.html file. (One is already generated)

What is expected?

The generated html file should have two picture elements which point to different images in both the source element and the img element. As seen in the source file at src/views/Home.vue.

What is actually happening?

In dist/static/index.html you will be able to see that the img elements have different src values which is correct. But the source elements both have the same srcset value which is incorrect.

@HcySunYang HcySunYang added 🐞 bug Something isn't working ❗ p4-important Priority 4: this fixes bugs that violate documented behavior, or significantly improves perf. 🔨 p3-minor-bug Priority 3: this fixes a bug, but is an edge case that only affects very specific usage. and removed ❗ p4-important Priority 4: this fixes bugs that violate documented behavior, or significantly improves perf. labels Apr 3, 2021
@lukewarlow
Copy link
Author

I've updated my test case to Vue 3.1.0-beta5 (https://github.com/lukewarlow/vue-server-render-bug) but I still experience the issue with incorrect srcset in the SSR output. Is there some change I need to make to my SSR code?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
🔨 p3-minor-bug Priority 3: this fixes a bug, but is an edge case that only affects very specific usage. 🐞 bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants