exportfunctionfinishComponentSetup(
instance: ComponentInternalInstance,
isSSR:boolean,
skipOptions?:boolean){const Component = instance.typeas ComponentOptions
......// template / render function normalization// could be already set when returned from setup()if(!instance.render){// only do on-the-fly compile if not in SSR - SSR on-the-fly compilation// is done by server-rendererif(!isSSR && compile &&!Component.render){......
Component.render =compile(template, finalCompilerOptions)if(__DEV__){endMeasure(instance,`compile`)}}}
instance.render =(Component.render ||NOOP)as InternalRenderFunction
// for runtime-compiled render functions using `with` blocks, the render// proxy used needs a different `has` handler which is more performant and// also only allows a whitelist of globals to fallthrough.if(installWithProxy){installWithProxy(instance)}}// support for 2.x optionsif(__FEATURE_OPTIONS_API__ &&!(__COMPAT__ && skipOptions)){setCurrentInstance(instance)pauseTracking()applyOptions(instance)resetTracking()unsetCurrentInstance()}// warn missing template/render// the runtime compilation of template in SSR is done by server-renderif(__DEV__ &&!Component.render && instance.render ===NOOP&&!isSSR){/* istanbul ignore if */if(!compile && Component.template){warn(`Component provided template option but `+`runtime compilation is not supported in this build of Vue.`+(__ESM_BUNDLER__
?` Configure your bundler to alias "vue" to "vue/dist/vue.esm-bundler.js".`: __ESM_BROWSER__
?` Use "vue.esm-browser.js" instead.`: __GLOBAL__
?` Use "vue.global.js" instead.`:``)/* should not happen */)}else{warn(`Component is missing template or render function.`)}}}