@vue/shared-canary
Advanced tools
Comparing version 3.20240624.0 to 3.20240624.1-minor.0
/** | ||
* @vue/shared-canary v3.20240624.0 | ||
* @vue/shared-canary v3.20240624.1-minor.0 | ||
* (c) 2018-present Yuxi (Evan) You and Vue contributors | ||
@@ -138,4 +138,4 @@ * @license MIT | ||
"2048": "DEV_ROOT_FRAGMENT", | ||
"HOISTED": -1, | ||
"-1": "HOISTED", | ||
"CACHED": -1, | ||
"-1": "CACHED", | ||
"BAIL": -2, | ||
@@ -200,3 +200,3 @@ "-2": "BAIL" | ||
const GLOBALS_ALLOWED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error"; | ||
const GLOBALS_ALLOWED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol"; | ||
const isGloballyAllowed = /* @__PURE__ */ makeMap(GLOBALS_ALLOWED); | ||
@@ -466,10 +466,7 @@ const isGloballyWhitelisted = isGloballyAllowed; | ||
const isRef = (val) => { | ||
return !!(val && val.__v_isRef === true); | ||
}; | ||
const toDisplayString = (val) => { | ||
return isString(val) ? val : val == null ? "" : isArray(val) || isObject(val) && (val.toString === objectToString || !isFunction(val.toString)) ? isRef(val) ? toDisplayString(val.value) : JSON.stringify(val, replacer, 2) : String(val); | ||
return isString(val) ? val : val == null ? "" : isArray(val) || isObject(val) && (val.toString === objectToString || !isFunction(val.toString)) ? JSON.stringify(val, replacer, 2) : String(val); | ||
}; | ||
const replacer = (_key, val) => { | ||
if (isRef(val)) { | ||
if (val && val["__v_isRef"]) { | ||
return replacer(_key, val.value); | ||
@@ -476,0 +473,0 @@ } else if (isMap(val)) { |
/** | ||
* @vue/shared-canary v3.20240624.0 | ||
* @vue/shared-canary v3.20240624.1-minor.0 | ||
* (c) 2018-present Yuxi (Evan) You and Vue contributors | ||
@@ -138,4 +138,4 @@ * @license MIT | ||
"2048": "DEV_ROOT_FRAGMENT", | ||
"HOISTED": -1, | ||
"-1": "HOISTED", | ||
"CACHED": -1, | ||
"-1": "CACHED", | ||
"BAIL": -2, | ||
@@ -200,3 +200,3 @@ "-2": "BAIL" | ||
const GLOBALS_ALLOWED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error"; | ||
const GLOBALS_ALLOWED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol"; | ||
const isGloballyAllowed = /* @__PURE__ */ makeMap(GLOBALS_ALLOWED); | ||
@@ -466,10 +466,7 @@ const isGloballyWhitelisted = isGloballyAllowed; | ||
const isRef = (val) => { | ||
return !!(val && val.__v_isRef === true); | ||
}; | ||
const toDisplayString = (val) => { | ||
return isString(val) ? val : val == null ? "" : isArray(val) || isObject(val) && (val.toString === objectToString || !isFunction(val.toString)) ? isRef(val) ? toDisplayString(val.value) : JSON.stringify(val, replacer, 2) : String(val); | ||
return isString(val) ? val : val == null ? "" : isArray(val) || isObject(val) && (val.toString === objectToString || !isFunction(val.toString)) ? JSON.stringify(val, replacer, 2) : String(val); | ||
}; | ||
const replacer = (_key, val) => { | ||
if (isRef(val)) { | ||
if (val && val["__v_isRef"]) { | ||
return replacer(_key, val.value); | ||
@@ -476,0 +473,0 @@ } else if (isMap(val)) { |
@@ -177,6 +177,6 @@ /** | ||
/** | ||
* Indicates a hoisted static vnode. This is a hint for hydration to skip | ||
* Indicates a cached static vnode. This is also a hint for hydration to skip | ||
* the entire sub tree since static content never needs to be updated. | ||
*/ | ||
HOISTED = -1, | ||
CACHED = -1, | ||
/** | ||
@@ -325,2 +325,10 @@ * A special flag that indicates that the diffing algorithm should bail out | ||
} ? F extends (value: infer V, ...args: infer _) => any ? Awaited<V> : never : T; | ||
/** | ||
* Utility for extracting the parameters from a function overload (for typed emits) | ||
* https://github.com/microsoft/TypeScript/issues/32164#issuecomment-1146737709 | ||
*/ | ||
export type OverloadParameters<T extends (...args: any[]) => any> = Parameters<OverloadUnion<T>>; | ||
type OverloadProps<TOverload> = Pick<TOverload, keyof TOverload>; | ||
type OverloadUnionRecursive<TOverload, TPartialOverload = unknown> = TOverload extends (...args: infer TArgs) => infer TReturn ? TPartialOverload extends TOverload ? never : OverloadUnionRecursive<TPartialOverload & TOverload, TPartialOverload & ((...args: TArgs) => TReturn) & OverloadProps<TOverload>> | ((...args: TArgs) => TReturn) : never; | ||
type OverloadUnion<TOverload extends (...args: any[]) => any> = Exclude<OverloadUnionRecursive<(() => never) & TOverload>, TOverload extends () => never ? never : () => never>; | ||
/** | ||
* @vue/shared-canary v3.20240624.0 | ||
* @vue/shared-canary v3.20240624.1-minor.0 | ||
* (c) 2018-present Yuxi (Evan) You and Vue contributors | ||
@@ -134,4 +134,4 @@ * @license MIT | ||
"2048": "DEV_ROOT_FRAGMENT", | ||
"HOISTED": -1, | ||
"-1": "HOISTED", | ||
"CACHED": -1, | ||
"-1": "CACHED", | ||
"BAIL": -2, | ||
@@ -196,3 +196,3 @@ "-2": "BAIL" | ||
const GLOBALS_ALLOWED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error"; | ||
const GLOBALS_ALLOWED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol"; | ||
const isGloballyAllowed = /* @__PURE__ */ makeMap(GLOBALS_ALLOWED); | ||
@@ -462,10 +462,7 @@ const isGloballyWhitelisted = isGloballyAllowed; | ||
const isRef = (val) => { | ||
return !!(val && val.__v_isRef === true); | ||
}; | ||
const toDisplayString = (val) => { | ||
return isString(val) ? val : val == null ? "" : isArray(val) || isObject(val) && (val.toString === objectToString || !isFunction(val.toString)) ? isRef(val) ? toDisplayString(val.value) : JSON.stringify(val, replacer, 2) : String(val); | ||
return isString(val) ? val : val == null ? "" : isArray(val) || isObject(val) && (val.toString === objectToString || !isFunction(val.toString)) ? JSON.stringify(val, replacer, 2) : String(val); | ||
}; | ||
const replacer = (_key, val) => { | ||
if (isRef(val)) { | ||
if (val && val["__v_isRef"]) { | ||
return replacer(_key, val.value); | ||
@@ -472,0 +469,0 @@ } else if (isMap(val)) { |
{ | ||
"name": "@vue/shared-canary", | ||
"version": "3.20240624.0", | ||
"version": "3.20240624.1-minor.0", | ||
"description": "internal utils shared across @vue packages", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
81958
1