【发布时间】:2017-03-26 12:23:04
【问题描述】:
如何更改标签的默认颜色?
这是默认的图表实现,希望有人能帮助我
<script>
import { Pie} from 'vue-chartjs'
export default Pie.extend({
props: ['one', 'two', 'three'],
mounted () {
// Overwriting base render method with actual data.
this.renderChart({
labels: ['One', 'Two', 'Three'],
datasets: [
{
label: 'Stuff',
backgroundColor: ['#C28535', '#8AAE56', '#B66C46'],
data: [this.one, this.two, this.three]
}
]
})
}
})
</script>
干杯
【问题讨论】:
标签: vue-chartjs