1๐
โ
As per documentation โ computed properties do not accept arguments, as instead represent a variable with custom get
and set
methods. Meaning, computed properties are accessed, not invoked.
In your case methods should be used. It will be reactive and re-computed when argument changes.
methods: {
hasWebsite (row) {
return !!(row.status !== 100 && row.supplier.websiteUrl);
}
}
Usage inside the template stays the same.
1๐
You should use a method instead of computed
property :
methods: {
hasWebsite: function(row){
console.log(row)
return !!(row.status !== 100 && row.supplier.websiteUrl);
}
Source:stackexchange.com