File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change 22
33// Importing these types declares them, so they are available globally
44
5- declare type Component = Object // eslint-disable-line no-undef
5+ declare type Component = Object | Function // eslint-disable-line no-undef
66declare type VNode = Object // eslint-disable-line no-undef
77declare type SlotValue = Component | string | Array < Component > | Array < string >
Original file line number Diff line number Diff line change @@ -55,7 +55,7 @@ export default function createInstance (
5555
5656 addEventLogger ( vue )
5757
58- const Constructor = vue . extend ( component )
58+ const Constructor = ( typeof component === 'function' && component . prototype instanceof Vue ) ? component : vue . extend ( component )
5959
6060 const instanceOptions = { ...options , propsData : { ...options . propsData } }
6161 deleteoptions ( instanceOptions )
You can’t perform that action at this time.
0 commit comments