【问题标题】:Laravel | Pass a Vue.js value to data-value in blade拉拉维尔 |将 Vue.js 值传递给刀片中的数据值
【发布时间】:2019-05-26 23:15:35
【问题描述】:

我想将 Vue.js 中的值 @{{cash.amount}} 传递给 data-value

<td scope="row"  data-value="HERE">@{{cash.amount}}</td>

我试过了,但没有用。

<td scope="row"  data-value="@{{cash.amount}}">@{{cash.amount}}</td>

谢谢

【问题讨论】:

  • 试试:data-value="cash.amount"

标签: javascript laravel vue.js vuejs2 vue-component


【解决方案1】:

你应该像这样绑定它:

 <td scope="row"  :data-value="cash.amount">@{{cash.amount}}</td>

<td scope="row"  v-bind:data-value="cash.amount">@{{cash.amount}}</td>

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2020-06-19
    • 2017-04-01
    • 2021-05-04
    • 1970-01-01
    • 1970-01-01
    • 2019-04-24
    • 2018-12-21
    相关资源
    最近更新 更多