Skip to content

Commit 8bb146c

Browse files
authored
Update componentdoc.vue
1 parent 2ea2ee9 commit 8bb146c

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

docs/components/componentdoc.vue

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,17 @@ export default {
189189
return {}
190190
}
191191
192-
const props = component.options.props
192+
let props = {}
193+
if (!component.options && typeof component === 'function') {
194+
// Async component that hans't been resolved yet.
195+
component((opts) => {
196+
props = opts.props || {}
197+
})
198+
} else {
199+
// Regular component
200+
props = component.options.props
201+
}
202+
193203
return Object.keys(props).map(prop => {
194204
const p = props[prop]
195205

0 commit comments

Comments
 (0)