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

@@ -1,11 +0,0 @@
export function ssrResolveCssVars(
source: Record<string, string>,
scopeId?: string
) {
const style: Record<string, string> = {}
const prefix = scopeId ? `${scopeId.replace(/^data-v-/, '')}-` : ``
for (const key in source) {
style[`--${prefix}${key}`] = source[key]
}
return { style }
}

View File

@@ -18,7 +18,6 @@ export {
export { ssrInterpolate } from './helpers/ssrInterpolate'
export { ssrRenderList } from './helpers/ssrRenderList'
export { ssrRenderSuspense } from './helpers/ssrRenderSuspense'
export { ssrResolveCssVars } from './helpers/ssrResolveCssVars'
// v-model helpers
export {