Releases: vueuse/vueuse
Releases · vueuse/vueuse
v10.4.1
v10.4.0
🚀 Features
- refAutoReset: Support maybe-ref as value - by @moander in #3342 (71685)
- useAsyncQueue: Support in infinite tasks in typescript - by @ethansnow2012 in #3333 (22e26)
- useBreakpoints: Add breakpoints for PrimeFlex - by @adrianrudnik and @antfu in #3317 (8b5ed)
- useDraggable: Allowing calculations of bounds with fixed element - by @linspw in #3335 (c08e5)
- useFetch: Introduce
updateDataOnError
option - by @climba03003 and @antfu in #3092 (945ca) - useIdbKeyval: Ability to wait for IDB writes - by @AbdallahAlhaddad and @antfu in #3338 (77a86)
- useWebNotification: Add
requestPermissions
option, returnpermissionGranted
andensurePermissions
- by @michealroberts and @antfu in #3325 (a1753)
🐞 Bug Fixes
- syncRef: Avoid infinite sync - by @chaii3 and @antfu in #3312 (bc966)
- useElementSize: Add
as
prop for component usage - by @menghany in #3274 (791f7) - useElementVisibility: Adjust threshold to 0 to fix visibility issue with large element - by @erikkkwu in #3308 (429ed)
- useFileSystemAccess: Make options to be optional - by @171h in #3320 (a9c8b)
- useMouse: Position won't be changed on page scroll when
type
ispage
, closes #2922 - by @CatsJuice and @antfu in #3244 and #2922 (c2f64) - useScroll: Evade edge case when window or document is Proxy - by @MinatoHikari in #3280 (c1b29)
- useScrollLock: Support using window or document - by @lzl0304 in #3319 (8acdb)
- useSortable: Fixed moveArrayElement repeatedly triggering side effects - by @Alfred-Skyblue in #3322 (b8515)
- useStorage: Read object only when it's serialized differently - by @chenglu4343, chenglu and @antfu in #2782 and #3091 (6fabe)
- useVModel: Clone set to true triggered infinite loop - by @motian and @antfu in #3097 (48f4c)
- useWebWorker: Prevent error event bubbling - by @Luvoy and @antfu in #3141 (34206)
- useWebsocket: PongTimeout auto-reconnect no work - by @shanyi-front and @antfu in #3321 (93372)
- useWebsocket: Reset pongTimeout on close - by @alipay404 and @antfu in #3324 (aea27)
- utils: Update
isClient
to checkdocument
too - by @brc-dd and @antfu in #3329 (786cb)
View changes on GitHub
v10.3.0
🚀 Features
- createReusableTemplate: Inherit attrs - by @wiidede and @antfu in #3226 (a32ae)
- useActiveElement: Search deeply in shadow dom - by @duoduoObama and @antfu in #3208 (296dc)
- useCounter: InitialValue support ref - by @Rock070 in #3266 (6ae3a)
- useFocus: Support
:focus-visible
- by @onmax and @antfu in #3254 (80329) - useRTDB: Add errorHandler option - by @wobsoriano in #3232 (b5e52)
- useSorted: Accept getter function as source - by @wvffle in #3249 (33a12)
- useSpeechSynthesis: Add reactivity for pitch and rate - by @shestmintsev-kirill in #3205 (ac88f)
🐞 Bug Fixes
- build: Ensure correct typing for node esm - by @xiaoxiangmoe and @antfu in #3209 (e7556)
- createReusableTemplate: Camelize props - by @94726, @antfu and @wvffle in #3253 (d79e1)
- onClickOutside: Fix outside click on html element in ios - by @sibbng in #3252 (9091e)
- reactiveComputed: Unwrap reactive type - by @sxzz in #3215 (17a72)
- router: Improves router functions: synchronize values, adds tests, and optimize performance - by @anteriovieira, @antfu, CJBoy and tzyoo in #3184 (0d02f)
- toRefs: Don't trigger unwanted watchEffects - by @wvffle in #3260 (5309c)
- useDateFormat: Handle zero properly - by @JocelynFloresz and @antfu in #3272 (d6428)
- useEventListener: Improved
useEventListener
overload - by @Alfred-Skyblue in #3246 (4f414) - useFetch: Generated payloadType on execute - by @tolking in #3251 (b7e3d)
- useInfiniteScroll: Improve visibility check - by @erikkkwu in #3212 (5ce61)
- useMediaQuery: Only add/remove event listeners on query change - by @Ingramz and @antfu in #3236 (f3969)
- useObjectUrl: Improve parameter type - by @ferreira-tb in #3239 (d3f7e)
- usePointer: Add
pointerup
event forpressure
field - by @cunzaizhuyi and @antfu in #3217 (ee425) - useScroll: Support configurable window - by @sheremet-va and @antfu in #3229 (dde41)
View changes on GitHub
v10.2.1
🚀 Features
- useDropZone: Expose more hooks - by @antfu (17d8d)
- useDropZone: Expose files as ref - by @antfu (6d4ef)
🐞 Bug Fixes
- fromEvent: Torn down properly - by @benlesh in #3155 (fa7ed)
- toRefs: Fix stack overflow caused by recursive
setPrototypeOf
- by @Alfred-Skyblue in #3166 (9f998) - useFullscreen: Skip exiting when not in fullscreen mode - by @tawen, @antfu and Fernando Fernández in #3144 (14edb)
- useInfiniteScroll: Prevent infinite load when v-show set false - by @wonderl17 in #3143 (a4dfa)
- useRafFn: Set initial delta to zero - by @haykkh in #3150 (cf6eb)
- useTimeoutPoll: Unexpected immediate execution - by @jiadesen in #3159 (7a897)
View changes on GitHub
v10.2.0
🚀 Features
- useAsyncQueue: Add
options.signal
parameter - by @cross-origin in #3033 (7da7c) - useColorMode: DisableTransition support pseudo-elements - by @lainbo in #3129 (78a3a)
- useDraggable: Improve component props - by @Alfred-Skyblue in #3075 (6b670)
- useElementByPoint: New
multiple
andinterval
options - by @okxiaoliang4 in #3089 (31b66) - useFileDialog: Add a parameter
reset
- by @zaqvil in #3059 (6d847) - useImage: Support referrerPolicy option - by @btea in #3132 (04d32)
- useSortable: Add option set get method - by @Alfred-Skyblue in #3108 (14283)
- useVModel: Improve types overload - by @Mini-ghost in #3055 (7d788)
🐞 Bug Fixes
- onClickOutside: Ensure focus on iframe captured in firefox - by @Geit in #3066 (2c66e)
- useAxios: Prevent premature loading refs reset - by @MickaelOth in #3076 (b1701)
- useCloned: Check for getter function to watch - by @ydcjeff in #3142 (6d630)
- useCssVar: Observe changes based on element class list - by @Waleed-KH in #3131 (9d34a)
- useMediaControls: Better representation for "waiting" value - by @ferferga in #3072 (0b253)
- useRouteHash,useRouteQuery,useRouteParams: Re-evaluates the value immediately - by @anteriovieira in #3002 (d5252)
- useScroll: Support window in setArrivedState - by @smallnine9 and yulj5 in #3086 (8855f)
- useScrollLock: Fix scrollable children check - by @valerypatorius in #3065 (cdc28)
- useTextareaAutosize: Autosize error when changing
input
asynchronously - by @jsonleex in #3118 (1b0ec) - useWebWorker: Add web worker transferable option - by @yassilah in #3123 (5988f)
- watchImmediate: Fix overload signature - by @ferreira-tb in #3114 (4b4e6)
🏎 Performance
- useCssVar: Only listen for style changes - by @Alfred-Skyblue in #3057 (3233a)
View changes on GitHub
v10.1.0
🚀 Features
- useAsyncState: Add support directly await - by @Hfutsora and @antfu in #3004 (d4db0)
- useColorMode: Expose
state
to the ref, deprecatedemitAuto
- by @Waleed-KH and @antfu in #2980 (a1bef) - useMouse: Support custom event extractor - by @RAX7 and @antfu in #2991 (4bb5b)
- watch:
watchImmediate
andwatchDeep
support overloads - by @Mini-ghost in #2998 (8f6a0)
🐞 Bug Fixes
- Dialog mask add z-index - by @recallwei in #3005 (07ebe)
- useColorMode: Element ref support, close #3003 - by @antfu in #3003 (adbbb)
- useCycleList: Correctly wrap list with ref - by @fan5530 and @antfu in #2988 (659b2)
- useDateFormat: Error if Y or YYY provided - by @dinocam1 and Dino Camdzic in #3001 (a2147)
- useFullscreen:
isFullscreen
handling for mutliple fullscreen elements - by @zaqvil and @antfu in #3000 (4a7a1) - useMediaControls: Apply state when target ref changes - by @ferferga in #2999 (b20aa)
- useSwipe: Ignore multiple touches - by @ARZarkesh in #2994 (995aa)
- useSwipe: Ignore multiple touches - by @ARZarkesh and @antfu in #2996 (af3ca)
- useTransition: Fix regression with non-linear transition functions - by @scottbedard in #2973 (8b330)
View changes on GitHub
v10.0.2
v10.0.1
v10.0.0
✨ Highlights
createReusableTemplate
from https://github.com/antfu/vue-reuse-templatecreateTemplatePromise
from https://github.com/antfu/vue-template-promiseuseAnimate
for native animation API, thanks to @tolking- Renamed
resolveRef
totoRef
,resolveUnref
totoValue
, aligning with Vue 3.3: vuejs/core#7997 - Improved tree-shaking
- Cleaned up long-lasting PRs, thanks to all!
🚨 Breaking Changes
- Remove deprecated types - by @Alfred-Skyblue in #2656 (c2fee)
- Remove
isFunction
andisString
utils (cb644) - computedAsync:
- toRef:
- Rename
resolveRef
totoRef
(10e98)
- Rename
- types:
- Rename
MaybeComputedRef
toMaybeRefOrGetter
(4d757)
- Rename
- useAxios:
- useColorMode:
- Enable
disableTransition
by default (5c82c)
- Enable
- useElementVisibility:
- Use useIntersectionObserver instead of scroll event handler - by @curtgrimes in #2551 (74b00)
- useEventBus,createEventHook:
- Dedupe registration of the same function - by @Alfred-Skyblue in #2748 (dd514)
- useFullscreen:
- useIDBKeyval:
- Return format changed, add
isFinished
- by @jssullivan and james.sullivan in #2474 (ef281)
- Return format changed, add
- useInfiniteScroll:
- useSwipe:
- Use literal for swipe direction instead of enum (f285c)
- useToFixed:
- Remove deprecated function (a6e5b)
- useUserMedia:
- Add constraints - remove deviceIds - by @mango-martin in #2032 (8f2a3)
- Remove deprecated apis (85468)
- useWebNotification:
- Should be exposed as EventHooksOn - by @Alfred-Skyblue and @antfu in #2821 (bcd2a)
- useWindowSize:
🚀 Features
- Update deps (e75a5)
- Improve tree-shaking (3275e)
- createEventHook:
- createGlobalState:
- Allow passing initial args - by @jd-solanki and @antfu in #2790 (f21b2)
- createReusableTemplate:
- createTemplatePromise:
- onKeyStroke:
- reactiveOmit:
- Add predicate parameter - by @Alfred-Skyblue and @antfu in #2849 (2e297)
- reactivePick:
- Add predicate parameter - by @Alfred-Skyblue in #2850 (0bde4)
- toRef:
- Support two argument overrides from Vue (f307f)
- toValue:
- Rename
resolveUnref
totoValue
(0a72b)
- Rename
- useAnimate:
- useArrayDifference:
- New function - by @Alfred-Skyblue in #2710 (a2a33)
- useArrayIncludes:
- New function - by @Alfred-Skyblue and @antfu in #2708 (4d6bc)
- useArrayUnique:
- Add a custom function to deduplicate - by @Alfred-Skyblue in #2612 (c8c30)
- useAsyncValidator:
- useAxios:
- Added
onFinish
callback - by @Alfred-Skyblue in #2829 (a2f33) - Added
initialData
andresetOnExecute
options - by @Alfred-Skyblue and @antfu in #2791 (f54a3)
- Added
- useBreakpoints:
- Getting current breakpoints - by @ineshbose and @antfu in #2906 (bbabd)
- useBrowserLocation:
- useColorMode:
- useCssVar:
- Introduce
observe
option - by @Alfred-Skyblue in #2800 (ae6e1)
- Introduce
- useCycleList:
- useDark:
- Passthrough default handler from
useColorSchema
- by @godismyjudge95 and @antfu in #2866 (d6d35)
- Passthrough default handler from
- useDark, useColorMode:
- Introduce
disableTransition
option (320ab)
- Introduce
- useDraggable:
v10.0.0-beta.5
🚨 Breaking Changes
- Remove
isFunction
andisString
utils - by @antfu (cb644) - useInfiniteScroll: Improve loading strategies, close #1701, close #1685 - by @antfu in #1701 and #1685 (d3a2b)
🚀 Features
- Improve tree-shaking - by @antfu (3275e)
- createReusableTemplate: New function - by @antfu in #2961 (bd53c)
- createTemplatePromise: New function - by @antfu and Enzo Innocenzi in #2957 (13169)