(
name: string,
component: DefineComponent<TComponentProps, {}, unknown>,
)
| 2 | import type { DefineComponent } from 'vue' |
| 3 | |
| 4 | export function createVuePlugin<TComponentProps extends Record<string, any>>( |
| 5 | name: string, |
| 6 | component: DefineComponent<TComponentProps, {}, unknown>, |
| 7 | ) { |
| 8 | function Plugin(props: TComponentProps) { |
| 9 | return { |
| 10 | name, |
| 11 | component, |
| 12 | props, |
| 13 | } |
| 14 | } |
| 15 | function NoOpPlugin(props: TComponentProps) { |
| 16 | return { |
| 17 | name, |
| 18 | component: Fragment, |
| 19 | props, |
| 20 | } |
| 21 | } |
| 22 | return [Plugin, NoOpPlugin] as const |
| 23 | } |
nothing calls this directly
no outgoing calls
no test coverage detected