Skip to content

Commit 3c09784

Browse files
authored
docs: fix Plugin type import (#929)
1 parent baf9773 commit 3c09784

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ or in TypeScript
146146
// BarChart.ts
147147
import { defineComponent, h, PropType } from 'vue'
148148
import { Bar } from 'vue-chartjs'
149-
import { Chart as ChartJS, Title, Tooltip, Legend, BarElement, CategoryScale, LinearScale, PluginOptionsByType } from 'chart.js'
149+
import { Chart as ChartJS, Title, Tooltip, Legend, BarElement, CategoryScale, LinearScale, Plugin } from 'chart.js'
150150

151151
ChartJS.register(Title, Tooltip, Legend, BarElement, CategoryScale, LinearScale)
152152

website/src/guide/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ or in TypeScript:
128128
```ts
129129
import { defineComponent, h, PropType } from 'vue'
130130
import { Bar } from 'vue-chartjs'
131-
import { Chart as ChartJS, Title, Tooltip, Legend, BarElement, CategoryScale, LinearScale, PluginOptionsByType } from 'chart.js'
131+
import { Chart as ChartJS, Title, Tooltip, Legend, BarElement, CategoryScale, LinearScale, Plugin } from 'chart.js'
132132

133133
ChartJS.register(Title, Tooltip, Legend, BarElement, CategoryScale, LinearScale)
134134

@@ -157,7 +157,7 @@ export default defineComponent({
157157
default: () => {}
158158
},
159159
plugins: {
160-
type: Object as PropType<PluginOptionsByType<'bar'>>,
160+
type: Object as PropType<Plugin<'bar'>>,
161161
default: () => {}
162162
}
163163
},

0 commit comments

Comments
 (0)