vant icon indicating copy to clipboard operation
vant copied to clipboard

Href link does not work

Open oddonet opened this issue 9 years ago • 4 comments

请认真写 PR 的标题,会用于生成 change log。

Do you want to request a feature or report a bug?

What is the current behavior? click the image does not go to the link specified by href

If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem via https://jsfiddle.net or similar (template: https://jsfiddle.net/n879nke7/). It appears the click event is used to stop the slide.

What is the expected behavior? Click the image it will follow the href link

Which versions of Vant and Vue, and which browser / OS are affected by this issue? Did this work in previous versions of Vant? vant: 0.8.4 Vue: 2.8.2

oddonet avatar Aug 19 '17 14:08 oddonet

do you mean the swipe component? href in swipe used like this

<van-swipe>
  <van-swipe-item v-for="(img, index) in images" :key="index">
    <a href="https://youzan.com" target="_blank">
      <img v-lazy="img" alt="">
    </a>
  </van-swipe-item>
</van-swipe>

pangxie1991 avatar Aug 19 '17 15:08 pangxie1991

@oddonet how to resolve this question , i can't add url in img

youmikuang avatar Dec 02 '18 18:12 youmikuang

Adding anchor tag works.

can you tell me how to use it

youmikuang avatar Dec 03 '18 15:12 youmikuang