From: Alexandre Bonaventure Geissmann Date: Fri, 5 Jun 2020 14:57:44 +0000 (-0400) Subject: fix(runtime-core): use array destructuring instead of object for edge compat (#1302) X-Git-Tag: v3.0.0-beta.15~57 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4a5021e763b7f49069e1f3d488bdddf910f09f3f;p=thirdparty%2Fvuejs%2Fcore.git fix(runtime-core): use array destructuring instead of object for edge compat (#1302) fix #1294 --- diff --git a/packages/runtime-core/src/componentProps.ts b/packages/runtime-core/src/componentProps.ts index d1989b5c65..c300e431b5 100644 --- a/packages/runtime-core/src/componentProps.ts +++ b/packages/runtime-core/src/componentProps.ts @@ -140,7 +140,7 @@ export function updateProps( } = instance const rawOptions = instance.type.props const rawCurrentProps = toRaw(props) - const { 0: options } = normalizePropsOptions(rawOptions) + const [options] = normalizePropsOptions(rawOptions) if ((optimized || patchFlag > 0) && !(patchFlag & PatchFlags.FULL_PROPS)) { if (patchFlag & PatchFlags.PROPS) { @@ -220,7 +220,7 @@ function setFullProps( props: Data, attrs: Data ) { - const { 0: options, 1: needCastKeys } = normalizePropsOptions( + const [options, needCastKeys] = normalizePropsOptions( instance.type.props ) const emits = instance.type.emits