wip: new cssVars SSR integration + fix cssVars SSR injection for suspense

This commit is contained in:
Evan You
2020-11-17 18:54:47 -05:00
parent 9297410569
commit cdc9f336fd
15 changed files with 117 additions and 103 deletions

View File

@@ -166,6 +166,7 @@ export interface TransformOptions extends SharedTransformCodegenOptions {
scopeId?: string | null
/**
* SFC `<style vars>` injection string
* Should already be an object expression, e.g. `{ 'xxxx-color': color }`
* needed to render inline CSS variables on component root
*/
ssrCssVars?: string

View File

@@ -245,7 +245,7 @@ export function resolveComponentType(
const builtIn = isCoreComponent(tag) || context.isBuiltInComponent(tag)
if (builtIn) {
// built-ins are simply fallthroughs / have special handling during ssr
// no we don't need to import their runtime equivalents
// so we don't need to import their runtime equivalents
if (!ssr) context.helper(builtIn)
return builtIn
}