I'm trying to conditionally apply a CSS class to a row (all b-table-column
) in a b-table
, like this:
<b-table-column class="is-unselectable"
:cell-class="{ 'has-pointer-cursor': props.row.url != null }"
field="version" label="Name" :custom-sort="sortName" sortable>
<!-- Content -->
</b-table-column>
The class has-pointer-cursor
exists in the style part of that vue
page/component.
I'm getting this error/warning in the console:
[Vue warn]: Invalid prop: type check failed for prop "cellClass". Expected String with value "[object Object]", got Object
found in ---> <BTableColumn> <BTable> <MyPage> at src/views/MyPage.vue <App> at src/App.vue <Root>
But somehow, it's working as expected (not taking into consideration the error message)!
What's happening and how it still works? Is there any way to fix it?
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.