gothinkster/vue-realworld-example-app

VTag: Use computed property for router link

開放

#194 建立於 2019年9月3日

 (5 則留言) (0 個反應) (0 位負責人)JavaScript (1,288 個分叉)batch import
difficulty:easygood first issuetype:enhancement

倉庫指標

星標
 (4,037 顆星)
PR 合併指標
 (30 天內沒有已合併 PR)

描述

<router-link
  :to="{ name: 'home-tag', params: { tag: name } }"
  :class="className"
>

Ideally, { name: 'home-tag', params: { tag: name } } should be a computed property and then used like:

<router-link
  :to="homeLink"
  :class="className"
>

Related resources:

貢獻者指南