\r\n \u003Cinput v-model=\"fields.address1\" />\r\n \u003Cinput type=\"checkbox\" v-model=\"fields.copyAddress1ToAddress2\" />\r\n \u003Cinput v-model=\"fields.address2\" :disabled=\"fields.copyAddress1ToAddress2\"/>\r\n \u003C/form>\r\n\u003C/template>\r\n```\r\n\r\n### Suggested solution\r\n\r\nThe implementation is very simple, currently I am copy/pasting it between projects:\r\n\r\n```ts\r\nimport type { UnwrapRef, WatchSource } from \"vue\"\r\n\r\n/** @returns ref which resets when the source changes */\r\nexport function computedRef\u003CT>(source: WatchSource\u003CT>) {\r\n const value = ref(toValue(source))\r\n watch(source, (source) => {\r\n value.value = source as UnwrapRef\u003CT>\r\n })\r\n return value\r\n}\r\n```\r\n\r\n### Alternative\r\n\r\nVueUse already has `reactiveComputed`, but it's not directly suitable, as it must always return an object. Therefore:\r\n\r\n1. It can't be used when the source data could be is unavailable (`reactiveComputed` can't return `undefined`).\r\n\r\n2. It can't be used when the ref is a non-object. For instance, consider a case when a list can be expanded and collapsed, which is a boolean ref. The default state (collapsed or expanded) could be dependent on the list length, such as it's expanded by default when it's 10 or less items, and collapsed if there's more. Then, when a list is updated, it must recalculate its expanded status based on the new length.\r\n\r\nOf course, we could always work around and return an object shaped as `{ value: \u003Cactual value, possibly undefined> }`, but why not have a function that uses a native Vue `Ref` for that case? It will also unwrap naturally in templates.\r\n\r\n### Additional context\r\n\r\nNaming is subject for discussion. For consistency with `reactiveComputed`, it could be `refComputed`. (To be honest, I would rather reverse both, `computedReactive` and `computedRef` read better in my thinking.)\r\n\r\n### Validations\r\n\r\n- [X] Follow our [Code of Conduct](https://github.com/vueuse/vueuse/blob/main/CODE_OF_CONDUCT.md)\r\n- [X] Read the [Contributing Guidelines](https://github.com/vueuse/vueuse/blob/main/CONTRIBUTING.md).\r\n- [X] Read the [docs](https://vueuse.org/guide).\r\n- [X] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.",[2975,2976],{"name":2935,"color":2936},{"name":2977,"color":2978},"new function","9C3E49",3485,"computedRef (same as reactiveComputed but returns a ref)","2025-03-16T06:35:25Z","https://github.com/vueuse/vueuse/issues/3485",0.7038672,{"description":2985,"labels":2986,"number":2987,"owner":2925,"repository":2925,"state":2967,"title":2988,"updated_at":2989,"url":2990,"score":2991},"### Describe the bug\n\nI'm trying to use the sortable integration with `useSortable` inside a component. The reordering of HTML elements works well, however, the call to `moveArrayElement` seems buggy:\r\n\u003Cimg width=\"201\" alt=\"Capture d’écran 2023-07-06 à 22 48 26\" src=\"https://github.com/vueuse/vueuse/assets/19361503/70674f3f-d7d4-4912-a468-85a0ffd855b2\">\r\nAs you can see, there is a log before the call and there is 3 items in the array; however, after the call, only two items are appearing ; the dragged item seems to disappear.\n\n### Reproduction\n\nhttps://codesandbox.io/p/sandbox/confident-mendel-6vjzsd?file=%2FREADME.md\n\n### System Info\n\n```Shell\nSystem:\r\n OS: macOS 13.4.1\r\n CPU: (8) arm64 Apple M1\r\n Memory: 466.89 MB / 16.00 GB\r\n Shell: 5.9 - /bin/zsh\r\n Binaries:\r\n Node: 20.4.0 - ~/.asdf/installs/nodejs/20.4.0/bin/node\r\n npm: 9.7.2 - ~/.asdf/plugins/nodejs/shims/npm\r\n Browsers:\r\n Chrome: 114.0.5735.198\r\n Safari: 16.5.1\r\n Safari Technology Preview: 17.0\r\n npmPackages:\r\n @vueuse/components: ^10.2.1 => 10.2.1 \r\n @vueuse/core: ^10.2.1 => 10.2.1 \r\n @vueuse/integrations: ^10.2.1 => 10.2.1 \r\n vue: ^3.3.4 => 3.3.4\n```\n\n\n### Used Package Manager\n\nnpm\n\n### Validations\n\n- [X] Follow our [Code of Conduct](https://github.com/vueuse/vueuse/blob/main/CODE_OF_CONDUCT.md)\n- [X] Read the [Contributing Guidelines](https://github.com/vueuse/vueuse/blob/main/CONTRIBUTING.md).\n- [X] Read the [docs](https://vueuse.org/guide).\n- [X] Check that there isn't [already an issue](https://github.com/vueuse/vueuse/issues) that reports the same bug to avoid creating a duplicate.\n- [X] Make sure this is a VueUse issue and not a framework-specific issue. For example, if it's a Vue SFC related bug, it should likely be reported to https://github.com/vuejs/core instead.\n- [X] Check that this is a concrete bug. For Q&A open a [GitHub Discussion](https://github.com/vueuse/vueuse/discussions).\n- [X] The provided reproduction is a [minimal reproducible example](https://stackoverflow.com/help/minimal-reproducible-example) of the bug.",[],3216,"Integrations/sortable : wrong number of items after `moveArrayElement` call","2024-02-14T11:14:14Z","https://github.com/vueuse/vueuse/issues/3216",0.7272326,{"description":2993,"labels":2994,"number":2996,"owner":2925,"repository":2925,"state":2967,"title":2997,"updated_at":2998,"url":2999,"score":3000},"### Clear and concise description of the problem\n\nscroll grabbing the background of any overflowed element with scroll.\r\n\r\n\n\n### Suggested solution\n\nuse directive to add the feature to an html element\r\n\r\n\r\n- the point change to grab onmousedown\r\n- you can drag in both direction to scroll horizontally and vertically\r\n- the point change to standard after onmouseup\n\n### Alternative\n\n_No response_\n\n### Additional context\n\n_No response_\n\n### Validations\n\n- [X] Follow our [Code of Conduct](https://github.com/vueuse/vueuse/blob/main/CODE_OF_CONDUCT.md)\n- [X] Read the [Contributing Guidelines](https://github.com/vueuse/vueuse/blob/main/CONTRIBUTING.md).\n- [X] Read the [docs](https://vueuse.org/guide).\n- [X] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.",[2995],{"name":2935,"color":2936},1681,"usePanToScroll","2023-02-14T16:15:26Z","https://github.com/vueuse/vueuse/issues/1681",0.7305317,{"description":3002,"labels":3003,"number":3008,"owner":2925,"repository":2925,"state":2967,"title":3009,"updated_at":3010,"url":3011,"score":3012},"### Clear and concise description of the problem\n\nPerhaps some businesses require watch to be paused by default\n\n### Suggested solution\n\nCan we add a parameter option to watchPausable so that the created watchPausable defaults to pausing the watch\n\n```\n watch: watchPausable(target, (a,b) => {\n \n }, {pause:true})\n```\n\n### Alternative\n\n_No response_\n\n### Additional context\n\n_No response_\n\n### Validations\n\n- [x] Follow our [Code of Conduct](https://github.com/vueuse/vueuse/blob/main/CODE_OF_CONDUCT.md)\n- [x] Read the [Contributing Guidelines](https://github.com/vueuse/vueuse/blob/main/CONTRIBUTING.md).\n- [x] Read the [docs](https://vueuse.org/guide).\n- [x] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.",[3004,3005],{"name":2935,"color":2936},{"name":3006,"color":3007},"has pr","5319E7",4515,"REQUEST | `watchPausable` | default watch pause","2025-02-12T02:28:02Z","https://github.com/vueuse/vueuse/issues/4515",0.7306226,{"description":3014,"labels":3015,"number":3016,"owner":2925,"repository":2925,"state":2967,"title":3017,"updated_at":3018,"url":3019,"score":3020},"### Describe the bug\n\nSame issue as #2924, which was fixed in #2926, the bug reappeared after merging #3322.\r\n\r\nThe problem mentioned in #3216.\r\nAfter `const element = array.splice(from, 1)[0]`, the missing element in `nextTick(console.log(array))` should be the expected behavior.\n\n### Reproduction\n\nhttps://vueuse.org/integrations/useSortable/\n\n### System Info\n\n```Shell\n-\n```\n\n\n### Used Package Manager\n\nnpm\n\n### Validations\n\n- [X] Follow our [Code of Conduct](https://github.com/vueuse/vueuse/blob/main/CODE_OF_CONDUCT.md)\n- [X] Read the [Contributing Guidelines](https://github.com/vueuse/vueuse/blob/main/CONTRIBUTING.md).\n- [X] Read the [docs](https://vueuse.org/guide).\n- [X] Check that there isn't [already an issue](https://github.com/vueuse/vueuse/issues) that reports the same bug to avoid creating a duplicate.\n- [X] Make sure this is a VueUse issue and not a framework-specific issue. For example, if it's a Vue SFC related bug, it should likely be reported to https://github.com/vuejs/core instead.\n- [X] Check that this is a concrete bug. For Q&A open a [GitHub Discussion](https://github.com/vueuse/vueuse/discussions).\n- [X] The provided reproduction is a [minimal reproducible example](https://stackoverflow.com/help/minimal-reproducible-example) of the bug.",[],4222,"useSortable: wrong order of elements","2024-11-21T08:11:16Z","https://github.com/vueuse/vueuse/issues/4222",0.73919636,["Reactive",3022],{},["Set"],["ShallowReactive",3025],{"$fTRc1wZytZ_XrK4EfJfei_Sz-An4H4Yy6syhVxH_PVJc":-1,"$fyPDxeWsF2xCd8bDwtHbjpYWa-bCp_PzFtK_44x9Gp3E":-1},"/vueuse/vueuse/4463"]