Evan You
f2ea25dc54
refactor(watch): reuse watch types
2024-08-20 16:16:25 +08:00
Rizumu Ayaka
205e5b5e27
feat(reactivity): base `watch`, `getCurrentWatcher`, and `onWatcherCleanup` ( #9927 )
2024-08-20 08:21:44 +08:00
Jakob
8bcaad4a32
fix(watch): handle errors in computed used as watch source ( #11626 )
...
close #11624
2024-08-16 16:14:08 +08:00
linzhe
3bda3e83fd
fix(reactivity): sync watch should be executed correctly ( #11589 )
...
close #11577
2024-08-13 22:54:08 +08:00
Kevin Deng 三咲智子
928af5fe2f
refactor(types): enable `isolatedDeclarations` ( #11178 )
2024-08-08 23:05:21 +08:00
远方os
267093c314
feat(reactivity/watch): add pause/resume for ReactiveEffect, EffectScope, and WatchHandle ( #9651 )
2024-08-02 14:41:27 +08:00
Damian Głowala
998dca59f1
feat(types): export `MultiWatchSources` type ( #9563 )
2024-08-02 12:43:22 +08:00
远方os
22f7d96757
feat(watch): support passing number to `deep` option to control the watch depth ( #9572 )
2024-08-02 11:38:07 +08:00
Evan You
f35080daf5
chore: Merge branch 'main' into minor
2024-07-31 16:49:22 +08:00
Tycho
e0b2975ef6
fix(types/ref): allow getter and setter types to be unrelated ( #11442 )
2024-07-29 10:52:38 +08:00
Evan You
26356264d2
chore: Merge branch 'main' into minor
2024-06-14 12:32:28 +02:00
Tycho
aae2d78875
fix(types/apiWatch): correct type inference for reactive array ( #11036 )
...
close #9416
2024-06-10 16:07:25 +08:00
Evan You
1d8727ec97
chore: Merge branch 'main' into minor
2024-05-30 11:21:12 +08:00
skirtle
a3e8aafbcc
fix(watch): support traversing symbol properties in deep watcher ( #10969 )
...
close #402
2024-05-30 11:03:44 +08:00
远方os
521988d7e1
types(runtime-core): add `OnCleanup` parameter type in `this.$watch` ( #9371 )
2024-05-28 00:25:07 +08:00
Evan You
801b8dea3b
chore: Merge branch 'main' into minor
2024-04-29 18:46:20 +08:00
skirtle
2d56816aa8
refactor: simplify traverse() for deep watchers ( #10795 )
2024-04-29 14:29:55 +08:00
Evan You
55660b0cfc
refactor(scheduler): use bitwise flags for scheduler jobs + optimize queueJob ( #10407 )
...
related: https://github.com/vuejs/core-vapor/pull/138
2024-02-26 10:22:12 +08:00
Evan You
05eb4e0fef
Refactor reactivity system to use version counting and doubly-linked list tracking ( #10397 )
...
Bug fixes
close #10236
close #10069
PRs made stale by this one
close #10290
close #10354
close #10189
close #9480
2024-02-25 16:51:49 +08:00
Evan You
7976f7044e
refactor(runtime-core): safer currentInstance reset
2024-01-09 07:22:13 +08:00
Yang Mingshan
d2d89551bb
fix(watch): cleanup watcher effect from scope when manually stopped ( #9978 )
2024-01-04 10:36:13 +08:00
丶远方
fe03b2f8bf
chore(apiWatch): constraint deep passes boolean ( #9952 )
2024-01-03 18:18:45 +08:00
Yang Mingshan
f300a4001e
fix(watch): remove instance unmounted short circuit in getter of `watchEffect` ( #9948 )
2024-01-03 18:09:53 +08:00
Evan You
a9f781a92c
fix(watch): revert watch behavior when watching shallow reactive objects
...
close #9965
2024-01-03 17:25:24 +08:00
Evan You
24d77c25ce
perf(watch): avoid double traverse for reactive source
2023-12-31 17:29:58 +08:00
yangxiuxiu
4f703d120d
fix(runtime-core): support deep: false when watch reactive ( #9928 )
...
close #9916
---------
Co-authored-by: RicardoErii <‘1974364190@qq.com’>
Co-authored-by: Evan You <yyx990803@gmail.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-12-30 18:52:17 +08:00
Carlos Rodrigues
4c20f502ca
chore: use relative import location instead of package ( #9941 )
2023-12-30 08:35:56 +08:00
丶远方
4af85835f7
fix(types): fix defineModel watch type error ( #9942 )
...
close #9939
2023-12-30 08:22:56 +08:00
三咲智子 Kevin Deng
bfe6b459d3
style: update format & lint config ( #9162 )
...
Co-authored-by: 丶远方 <yangpanteng@gmail.com>
Co-authored-by: 三咲智子 Kevin Deng <sxzz@sxzz.moe>
Co-authored-by: Guo Xingjun <99574369+Plumbiu@users.noreply.github.com>
2023-12-26 19:39:47 +08:00
Evan You
1ea775633d
chore: Merge branch 'main' into minor
2023-11-21 09:48:26 +08:00
renovate[bot]
16a6438236
chore(deps): update lint ( #9627 )
...
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-11-18 10:33:24 +08:00
花果山大圣
73fd810eeb
fix(reactivity): onCleanup also needs to be cleaned ( #8655 )
...
close #5151
close #7695
2023-11-10 16:47:08 +08:00
Johnson Chu
16e06ca08f
feat(reactivity): more efficient reactivity system ( #5912 )
...
fix #311 , fix #1811 , fix #6018 , fix #7160 , fix #8714 , fix #9149 , fix #9419 , fix #9464
2023-10-27 23:28:40 +09:00
丶远方
a645e7aa51
feat(runtime-core): add `once` option to watch ( #9034 )
2023-10-27 23:28:40 +09:00
丶远方
3798c5480b
chore: remove unnecessary type assertions ( #8311 )
2023-05-19 07:49:28 +08:00
Evan You
6213b73cd2
build: custom const enum processing
2023-02-03 09:54:15 +08:00
Anthony Fu
4a16b204be
chore: run format
2023-01-12 12:58:11 +01:00
Thorsten Lünborg
cd7c887b75
fix(reactivity): ensure watch(Effect) can run independent of unmounted instance if created in a detatched effectScope ( fix #7319 ) ( #7330 )
...
* fix(reactivity): ensure watch(Effect) can run independent of unmounted instance if created in a detatched effectScope
* test: use separate counters for each watcher to make test more robust
2023-01-09 15:20:21 +01:00
webfansplz
11bd8db768
chore(types): remove unnecessary type assertions ( #7032 )
2022-11-14 01:44:06 -05:00
Thorsten Lünborg
5dc593ba28
fix(watch): for immediate watch with single source, ensure cb is called with undefined as oldValue ( #7075 )
...
fix : #7074
2022-11-09 18:19:35 -05:00
Evan You
23e85e21a5
fix(watch): ensure oldValue in multi-source watcher is always an array
...
fix #7070
2022-11-09 20:50:02 +08:00
webfansplz
0e0976168f
fix(ssr/watch) flush: sync watchers should work in ssr ( #6139 )
...
fix #6013
2022-10-26 06:30:15 -04:00
Thorsten Lünborg
bc167b5c6c
fix(runtime-core): watching multiple values - handle `undefined` as initial values ( fix : #5032 ) ( #5033 )
2022-10-20 21:45:05 +02:00
Evan You
78c199d6db
fix(watch): flush:pre watchers should not fire if state change causes
...
owner component to unmount
fix #2291
2022-08-15 19:00:55 +08:00
edison
220f255fe9
fix(watch): fix watching multiple sources containing shallowRef ( #5381 )
...
fix #5371
2022-05-12 20:20:04 -04:00
Evan You
74d2a76af6
fix(watch): fix flush: pre watchers triggered synchronously in setup
...
fix #5721
2022-04-15 18:08:44 +08:00
Evan You
7efb9dba30
refactor: remove use of Object.assign
...
TS already transpiles spread to Object.assign with target:es2016
2022-04-12 15:22:11 +08:00
Evan You
9fda9411ec
feat(reactivity): add isShallow api
2022-01-18 09:22:41 +08:00
Evan You
ce49fdf999
refactor: more readable type names for watch cleanup function
2022-01-12 22:07:47 +08:00
Evan You
87c86e4cc2
refactor: ensure ssr branches are included in esm-bundler build
2021-09-23 15:02:19 -04:00