Closed baronkoko closed 2 years ago
Method html helped. Everything worked
img(
src='~@/assets/images/img.png',
srcset='~@/assets/images/img@2x.png 2x, ~@/assets/images/img@3x.png 3x',
alt='My image'
)
Thank you for your work!
Hello @baronkoko,
thank you for interesting usage case.
I have implemented the resolving for srcset
in the new version 1.6.2
.
Now all methods can correct resolve it.
For example:
img(srcset=`${require('./image1.jpeg')} 320w, ${require('./image2.jpeg')} 640w` src=require('./image.jpeg'))
output
<img srcset="/assets/image1.f78b30f4.jpeg 320w, /assets/image2.f78b30f4.jpeg 640w" src="/assets/image.f78b30f4.jpeg">
You can see the test case.
@webdiscus Wow, thanks for the quick response and solution!
Hi, is it possible to use such a feature?
This code currently gives the following error:
Error: Error parsing body of the with expression
Stack: