computed: {
starSize () {
return 'star-' + this.size
},
itemClasses () {
console.log(this.scode)
let result = []
let staron = Math.floor(this.scode)
for (let i = 0; i < staron.length; i++) {
result.push(starOn)
}
if (this.scode !== Math.floor(this.scode)) {
result.push(starHalf)
}
while (result.length < LENGTH) {
result.push(starOff)
}
return result
}
掌握Vue1.0到2.0再到2.5最全版本应用与迭代,打造极致流畅的WebApp
了解课程