chore: fix typos (#1090)
This commit is contained in:
@@ -26,7 +26,7 @@ return function render(_ctx, _cache) {
|
||||
}"
|
||||
`;
|
||||
|
||||
exports[`compiler: transform v-model simple exprssion (with prefixIdentifiers) 1`] = `
|
||||
exports[`compiler: transform v-model simple expression (with prefixIdentifiers) 1`] = `
|
||||
"import { createVNode as _createVNode, openBlock as _openBlock, createBlock as _createBlock } from \\"vue\\"
|
||||
|
||||
export function render(_ctx, _cache) {
|
||||
@@ -37,7 +37,7 @@ export function render(_ctx, _cache) {
|
||||
}"
|
||||
`;
|
||||
|
||||
exports[`compiler: transform v-model simple exprssion 1`] = `
|
||||
exports[`compiler: transform v-model simple expression 1`] = `
|
||||
"const _Vue = Vue
|
||||
|
||||
return function render(_ctx, _cache) {
|
||||
|
||||
@@ -39,7 +39,7 @@ function parseWithVModel(template: string, options: CompilerOptions = {}) {
|
||||
}
|
||||
|
||||
describe('compiler: transform v-model', () => {
|
||||
test('simple exprssion', () => {
|
||||
test('simple expression', () => {
|
||||
const root = parseWithVModel('<input v-model="model" />')
|
||||
const node = root.children[0] as ElementNode
|
||||
const props = ((node.codegenNode as VNodeCall).props as ObjectExpression)
|
||||
@@ -76,7 +76,7 @@ describe('compiler: transform v-model', () => {
|
||||
expect(generate(root).code).toMatchSnapshot()
|
||||
})
|
||||
|
||||
test('simple exprssion (with prefixIdentifiers)', () => {
|
||||
test('simple expression (with prefixIdentifiers)', () => {
|
||||
const root = parseWithVModel('<input v-model="model" />', {
|
||||
prefixIdentifiers: true
|
||||
})
|
||||
@@ -377,7 +377,7 @@ describe('compiler: transform v-model', () => {
|
||||
expect(codegen.dynamicProps).toBe(`["modelValue", "onUpdate:modelValue"]`)
|
||||
})
|
||||
|
||||
test('should generate modelModifers for component v-model', () => {
|
||||
test('should generate modelModifiers for component v-model', () => {
|
||||
const root = parseWithVModel('<Comp v-model.trim.bar-baz="foo" />', {
|
||||
prefixIdentifiers: true
|
||||
})
|
||||
@@ -399,7 +399,7 @@ describe('compiler: transform v-model', () => {
|
||||
expect(vnodeCall.dynamicProps).toBe(`["modelValue", "onUpdate:modelValue"]`)
|
||||
})
|
||||
|
||||
test('should generate modelModifers for component v-model with arguments', () => {
|
||||
test('should generate modelModifiers for component v-model with arguments', () => {
|
||||
const root = parseWithVModel(
|
||||
'<Comp v-model:foo.trim="foo" v-model:bar.number="bar" />',
|
||||
{
|
||||
|
||||
@@ -31,7 +31,7 @@ type MergedParserOptions = Omit<Required<ParserOptions>, OptionalOptions> &
|
||||
Pick<ParserOptions, OptionalOptions>
|
||||
|
||||
// The default decoder only provides escapes for characters reserved as part of
|
||||
// the tempalte syntax, and is only used if the custom renderer did not provide
|
||||
// the template syntax, and is only used if the custom renderer did not provide
|
||||
// a platform-specific decoder.
|
||||
const decodeRE = /&(gt|lt|amp|apos|quot);/g
|
||||
const decodeMap: Record<string, string> = {
|
||||
|
||||
@@ -19,7 +19,7 @@ export function hoistStatic(root: RootNode, context: TransformContext) {
|
||||
root.children,
|
||||
context,
|
||||
new Map(),
|
||||
// Root node is unfortuantely non-hoistable due to potential parent
|
||||
// Root node is unfortunately non-hoistable due to potential parent
|
||||
// fallthrough attributes.
|
||||
isSingleElementRoot(root, root.children[0])
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user