chore: revert prettier
This commit is contained in:
parent
b5886189ba
commit
af57ad110f
@ -37,7 +37,7 @@
|
|||||||
"lerna": "^3.16.4",
|
"lerna": "^3.16.4",
|
||||||
"lint-staged": "^9.2.3",
|
"lint-staged": "^9.2.3",
|
||||||
"minimist": "^1.2.0",
|
"minimist": "^1.2.0",
|
||||||
"prettier": "^1.18.2",
|
"prettier": "~1.14.0",
|
||||||
"rollup": "^1.19.4",
|
"rollup": "^1.19.4",
|
||||||
"rollup-plugin-alias": "^2.0.0",
|
"rollup-plugin-alias": "^2.0.0",
|
||||||
"rollup-plugin-json": "^4.0.0",
|
"rollup-plugin-json": "^4.0.0",
|
||||||
|
@ -77,6 +77,4 @@ export type UnwrapRef<T> = {
|
|||||||
? 'array'
|
? 'array'
|
||||||
: T extends Function | CollectionTypes
|
: T extends Function | CollectionTypes
|
||||||
? 'ref' // bail out on types that shouldn't be unwrapped
|
? 'ref' // bail out on types that shouldn't be unwrapped
|
||||||
: T extends object
|
: T extends object ? 'object' : 'ref']
|
||||||
? 'object'
|
|
||||||
: 'ref']
|
|
||||||
|
@ -61,7 +61,7 @@ export function watch<T>(
|
|||||||
): StopHandle
|
): StopHandle
|
||||||
|
|
||||||
// overload #3: array of multiple sources + cb
|
// overload #3: array of multiple sources + cb
|
||||||
export function watch<T extends readonly WatcherSource<unknown>[]>(
|
export function watch<T extends Readonly<WatcherSource<unknown>[]>>(
|
||||||
sources: T,
|
sources: T,
|
||||||
cb: WatchHandler<MapSources<T>>,
|
cb: WatchHandler<MapSources<T>>,
|
||||||
options?: WatchOptions
|
options?: WatchOptions
|
||||||
@ -94,7 +94,8 @@ function doWatch(
|
|||||||
let getter: () => any
|
let getter: () => any
|
||||||
if (isArray(source)) {
|
if (isArray(source)) {
|
||||||
getter = () =>
|
getter = () =>
|
||||||
source.map(s =>
|
source.map(
|
||||||
|
s =>
|
||||||
isRef(s)
|
isRef(s)
|
||||||
? s.value
|
? s.value
|
||||||
: callWithErrorHandling(s, instance, ErrorCodes.WATCH_GETTER)
|
: callWithErrorHandling(s, instance, ErrorCodes.WATCH_GETTER)
|
||||||
|
@ -56,9 +56,7 @@ type InferPropType<T> = T extends null
|
|||||||
? any // somehow `ObjectConstructor` when inferred from { (): T } becomes `any`
|
? any // somehow `ObjectConstructor` when inferred from { (): T } becomes `any`
|
||||||
: T extends ObjectConstructor | { type: ObjectConstructor }
|
: T extends ObjectConstructor | { type: ObjectConstructor }
|
||||||
? { [key: string]: any }
|
? { [key: string]: any }
|
||||||
: T extends Prop<infer V>
|
: T extends Prop<infer V> ? V : T
|
||||||
? V
|
|
||||||
: T
|
|
||||||
|
|
||||||
export type ExtractPropTypes<
|
export type ExtractPropTypes<
|
||||||
O,
|
O,
|
||||||
|
@ -1162,23 +1162,14 @@ export function createRenderer<
|
|||||||
) {
|
) {
|
||||||
// create reactive effect for rendering
|
// create reactive effect for rendering
|
||||||
let mounted = false
|
let mounted = false
|
||||||
instance.update = effect(
|
instance.update = effect(function componentEffect() {
|
||||||
function componentEffect() {
|
|
||||||
if (!mounted) {
|
if (!mounted) {
|
||||||
const subTree = (instance.subTree = renderComponentRoot(instance))
|
const subTree = (instance.subTree = renderComponentRoot(instance))
|
||||||
// beforeMount hook
|
// beforeMount hook
|
||||||
if (instance.bm !== null) {
|
if (instance.bm !== null) {
|
||||||
invokeHooks(instance.bm)
|
invokeHooks(instance.bm)
|
||||||
}
|
}
|
||||||
patch(
|
patch(null, subTree, container, anchor, instance, parentSuspense, isSVG)
|
||||||
null,
|
|
||||||
subTree,
|
|
||||||
container,
|
|
||||||
anchor,
|
|
||||||
instance,
|
|
||||||
parentSuspense,
|
|
||||||
isSVG
|
|
||||||
)
|
|
||||||
initialVNode.el = subTree.el
|
initialVNode.el = subTree.el
|
||||||
// mounted hook
|
// mounted hook
|
||||||
if (instance.m !== null) {
|
if (instance.m !== null) {
|
||||||
@ -1236,9 +1227,7 @@ export function createRenderer<
|
|||||||
popWarningContext()
|
popWarningContext()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
}, __DEV__ ? createDevEffectOptions(instance) : prodEffectOptions)
|
||||||
__DEV__ ? createDevEffectOptions(instance) : prodEffectOptions
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function updateComponentPreRender(
|
function updateComponentPreRender(
|
||||||
|
@ -35,7 +35,9 @@ function toNumber(val: string): number | string {
|
|||||||
|
|
||||||
// We are exporting the v-model runtime directly as vnode hooks so that it can
|
// We are exporting the v-model runtime directly as vnode hooks so that it can
|
||||||
// be tree-shaken in case v-model is never used.
|
// be tree-shaken in case v-model is never used.
|
||||||
export const vModelText: ObjectDirective<HTMLInputElement | HTMLTextAreaElement> = {
|
export const vModelText: ObjectDirective<
|
||||||
|
HTMLInputElement | HTMLTextAreaElement
|
||||||
|
> = {
|
||||||
beforeMount(el, { value, modifiers: { lazy, trim, number } }, vnode) {
|
beforeMount(el, { value, modifiers: { lazy, trim, number } }, vnode) {
|
||||||
el.value = value
|
el.value = value
|
||||||
const assign = getModelAssigner(vnode)
|
const assign = getModelAssigner(vnode)
|
||||||
|
@ -5597,10 +5597,10 @@ prelude-ls@~1.1.2:
|
|||||||
resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54"
|
resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54"
|
||||||
integrity sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=
|
integrity sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=
|
||||||
|
|
||||||
prettier@^1.18.2:
|
prettier@~1.14.0:
|
||||||
version "1.18.2"
|
version "1.14.3"
|
||||||
resolved "https://registry.yarnpkg.com/prettier/-/prettier-1.18.2.tgz#6823e7c5900017b4bd3acf46fe9ac4b4d7bda9ea"
|
resolved "https://registry.yarnpkg.com/prettier/-/prettier-1.14.3.tgz#90238dd4c0684b7edce5f83b0fb7328e48bd0895"
|
||||||
integrity sha512-OeHeMc0JhFE9idD4ZdtNibzY0+TPHSpSSb9h8FqtP+YnoZZ1sl8Vc9b1sasjfymH3SonAF4QcA2+mzHPhMvIiw==
|
integrity sha512-qZDVnCrnpsRJJq5nSsiHCE3BYMED2OtsI+cmzIzF1QIfqm5ALf8tEJcO27zV1gKNKRPdhjO0dNWnrzssDQ1tFg==
|
||||||
|
|
||||||
pretty-format@^24.9.0:
|
pretty-format@^24.9.0:
|
||||||
version "24.9.0"
|
version "24.9.0"
|
||||||
|
Loading…
Reference in New Issue
Block a user