import { createRenderer , CreateAppFunction , App } from '@vue/runtime-core' ; import { isNativeWidget } from '../widgets/nativeWidget' ; import { VNWindow } from '../widgets/Window/VNWindow' ; import rendererOptions from './nodeOps' ; const renderer = createRenderer ( rendererOptions ) ; function injectNativeTagCheck ( app ) { Object . defineProperty ( app . config , 'isNativeTag' , { value : isNativeWidget , writable : false , } ) ; } export const createApp = ( ... args ) => { const app = renderer . createApp ( ... args ) ; injectNativeTagCheck ( app ) ; const { mount } = app ; app . mount = ( ) => { const container = new VNWindow ( ) ; container . show ( ) ; global . win = container ; return mount ( container ) ; } ; return app ; } ;