Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/laravel/10.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 使用VueJS2呈现表_Php_Laravel_Vue.js - Fatal编程技术网

Php 使用VueJS2呈现表

Php 使用VueJS2呈现表,php,laravel,vue.js,Php,Laravel,Vue.js,我正在将JQuery管理的表迁移到VueJS(2.4.4) 对于服务器渲染,我使用Laravel,因此: <div class="container-fluid"> <table class="table table-togglable table-hover"> <thead> <tr> <th data-toggle="true">Name</th>

我正在将JQuery管理的表迁移到VueJS(2.4.4) 对于服务器渲染,我使用Laravel,因此:

<div class="container-fluid">
<table class="table table-togglable table-hover">
    <thead>
        <tr>
            <th data-toggle="true">Name</th>
            <th class="text-center" data-hide="phone">Federation</th>
        </tr>
    </thead>
    <tbody>
        @foreach($associations as $association) // This is Laravel blade
            <association-item
                    :association="{{ json_encode($association) }}"
                    :url_edit="{{ json_encode(route('associations.edit', $association)) }}"
                    :url_delete="{{ json_encode(route('api.associations.delete', $association)) }}"
            >
            </association-item>
        @endforeach
    </tbody>
</table>
</div>
所以,它是有效的,当我看到源代码时,我的

但是在屏幕上,数据在标题之前,当我用Chrome调试时,我可以看到所有
项目
都在
之间,唯一的标记是
tr

您应该能够使用指定组件

<tr is="association-item" ...>

使HTML合法化。(可能需要是
is=“associationItem”

唯一的标记是
tr

您应该能够使用指定组件

<tr is="association-item" ...>

使HTML合法化。(可能需要是
is=“associationItem”

<tr is="association-item" ...>