forked from vuejs/core
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch '3.2' into types/string_type_inference
- Loading branch information
Showing
129 changed files
with
4,809 additions
and
1,855 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
52 changes: 24 additions & 28 deletions
52
packages/compiler-core/__tests__/__snapshots__/scopeId.spec.ts.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,82 +1,78 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`scopeId compiler support should push scopeId for hoisted nodes 1`] = ` | ||
"import { createVNode as _createVNode, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, openBlock as _openBlock, createBlock as _createBlock, withScopeId as _withScopeId, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \\"vue\\" | ||
const _withId = /*#__PURE__*/_withScopeId(\\"test\\") | ||
"import { createElementVNode as _createElementVNode, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, openBlock as _openBlock, createElementBlock as _createElementBlock, withScopeId as _withScopeId, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \\"vue\\" | ||
_pushScopeId(\\"test\\") | ||
const _hoisted_1 = /*#__PURE__*/_createVNode(\\"div\\", null, \\"hello\\", -1 /* HOISTED */) | ||
const _hoisted_2 = /*#__PURE__*/_createVNode(\\"div\\", null, \\"world\\", -1 /* HOISTED */) | ||
const _hoisted_1 = /*#__PURE__*/_createElementVNode(\\"div\\", null, \\"hello\\", -1 /* HOISTED */) | ||
const _hoisted_2 = /*#__PURE__*/_createElementVNode(\\"div\\", null, \\"world\\", -1 /* HOISTED */) | ||
_popScopeId() | ||
export const render = /*#__PURE__*/_withId((_ctx, _cache) => { | ||
return (_openBlock(), _createBlock(\\"div\\", null, [ | ||
export function render(_ctx, _cache) { | ||
return (_openBlock(), _createElementBlock(\\"div\\", null, [ | ||
_hoisted_1, | ||
_createTextVNode(_toDisplayString(_ctx.foo), 1 /* TEXT */), | ||
_hoisted_2 | ||
])) | ||
})" | ||
}" | ||
`; | ||
|
||
exports[`scopeId compiler support should wrap default slot 1`] = ` | ||
"import { createVNode as _createVNode, resolveComponent as _resolveComponent, withCtx as _withCtx, openBlock as _openBlock, createBlock as _createBlock, withScopeId as _withScopeId } from \\"vue\\" | ||
const _withId = /*#__PURE__*/_withScopeId(\\"test\\") | ||
"import { createElementVNode as _createElementVNode, resolveComponent as _resolveComponent, withCtx as _withCtx, openBlock as _openBlock, createBlock as _createBlock, withScopeId as _withScopeId } from \\"vue\\" | ||
export const render = /*#__PURE__*/_withId((_ctx, _cache) => { | ||
export function render(_ctx, _cache) { | ||
const _component_Child = _resolveComponent(\\"Child\\") | ||
return (_openBlock(), _createBlock(_component_Child, null, { | ||
default: _withId(() => [ | ||
_createVNode(\\"div\\") | ||
default: _withCtx(() => [ | ||
_createElementVNode(\\"div\\") | ||
]), | ||
_: 1 /* STABLE */ | ||
})) | ||
})" | ||
}" | ||
`; | ||
|
||
exports[`scopeId compiler support should wrap dynamic slots 1`] = ` | ||
"import { createVNode as _createVNode, resolveComponent as _resolveComponent, withCtx as _withCtx, renderList as _renderList, createSlots as _createSlots, openBlock as _openBlock, createBlock as _createBlock, withScopeId as _withScopeId } from \\"vue\\" | ||
const _withId = /*#__PURE__*/_withScopeId(\\"test\\") | ||
"import { createElementVNode as _createElementVNode, resolveComponent as _resolveComponent, withCtx as _withCtx, renderList as _renderList, createSlots as _createSlots, openBlock as _openBlock, createBlock as _createBlock, withScopeId as _withScopeId } from \\"vue\\" | ||
export const render = /*#__PURE__*/_withId((_ctx, _cache) => { | ||
export function render(_ctx, _cache) { | ||
const _component_Child = _resolveComponent(\\"Child\\") | ||
return (_openBlock(), _createBlock(_component_Child, null, _createSlots({ _: 2 /* DYNAMIC */ }, [ | ||
(_ctx.ok) | ||
? { | ||
name: \\"foo\\", | ||
fn: _withId(() => [ | ||
_createVNode(\\"div\\") | ||
fn: _withCtx(() => [ | ||
_createElementVNode(\\"div\\") | ||
]) | ||
} | ||
: undefined, | ||
_renderList(_ctx.list, (i) => { | ||
return { | ||
name: i, | ||
fn: _withId(() => [ | ||
_createVNode(\\"div\\") | ||
fn: _withCtx(() => [ | ||
_createElementVNode(\\"div\\") | ||
]) | ||
} | ||
}) | ||
]), 1024 /* DYNAMIC_SLOTS */)) | ||
})" | ||
}" | ||
`; | ||
|
||
exports[`scopeId compiler support should wrap named slots 1`] = ` | ||
"import { toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, createVNode as _createVNode, resolveComponent as _resolveComponent, withCtx as _withCtx, openBlock as _openBlock, createBlock as _createBlock, withScopeId as _withScopeId } from \\"vue\\" | ||
const _withId = /*#__PURE__*/_withScopeId(\\"test\\") | ||
"import { toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, createElementVNode as _createElementVNode, resolveComponent as _resolveComponent, withCtx as _withCtx, openBlock as _openBlock, createBlock as _createBlock, withScopeId as _withScopeId } from \\"vue\\" | ||
export const render = /*#__PURE__*/_withId((_ctx, _cache) => { | ||
export function render(_ctx, _cache) { | ||
const _component_Child = _resolveComponent(\\"Child\\") | ||
return (_openBlock(), _createBlock(_component_Child, null, { | ||
foo: _withId(({ msg }) => [ | ||
foo: _withCtx(({ msg }) => [ | ||
_createTextVNode(_toDisplayString(msg), 1 /* TEXT */) | ||
]), | ||
bar: _withId(() => [ | ||
_createVNode(\\"div\\") | ||
bar: _withCtx(() => [ | ||
_createElementVNode(\\"div\\") | ||
]), | ||
_: 1 /* STABLE */ | ||
})) | ||
})" | ||
}" | ||
`; |
Oops, something went wrong.