Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(all): use MaybeComputedRef #1768

Merged
merged 24 commits into from Jul 8, 2022
Merged

feat(all): use MaybeComputedRef #1768

merged 24 commits into from Jul 8, 2022

Conversation

antfu
Copy link
Member

@antfu antfu commented Jul 6, 2022

Continue from #1743, plan for v9.0

For example, currently we have to:

const title = computed(() => `${foo} | template`)
useTitle(title)

Later it will be possible to have:

useTitle(() => `${foo} | template`)

TODO

@antfu antfu added this to the 9.0 milestone Jul 6, 2022
@antfu antfu marked this pull request as draft July 6, 2022 17:54
@antfu antfu mentioned this pull request Jul 6, 2022
8 tasks
@sxzz
Copy link
Member

sxzz commented Jul 7, 2022

I can make PRs to contribute

@sxzz
Copy link
Member

sxzz commented Jul 7, 2022

We can make a list to trace the progress of refactoring

  • useBluetooth
  • useBreakpoints
  • useBroadcastChannel
  • useBrowserLocation
  • useClipboard
  • useColorMode
  • useCssVar
  • useDark
  • useEventListener
  • useEyeDropper
  • useFavicon
  • useFileDialog
  • useFileSystemAccess
  • useFullscreen
  • useGamepad
  • useImage
  • useMediaControls
  • useMediaQuery
  • useMemory
  • useObjectUrl
  • usePermission
  • usePreferredColorScheme
  • usePreferredDark
  • usePreferredLanguages
  • useScreenOrientation
  • useScreenSafeArea
  • useScriptTag
  • useShare
  • useStyleTag
  • useTextareaAutosize
  • useTitle
  • useUrlSearchParams
  • useVibrate
  • useWakeLock
  • useWebNotification
  • onClickOutside
  • onKeyStroke
  • onLongPress
  • onStartTyping
  • useBattery
  • useDeviceMotion
  • useDeviceOrientation
  • useDevicePixelRatio
  • useDevicesList
  • useDisplayMedia
  • useElementByPoint
  • useElementHover
  • useFocus
  • useFocusWithin
  • useFps
  • useGeolocation
  • useIdle
  • useInfiniteScroll
  • useKeyModifier
  • useMagicKeys
  • useMouse
  • useMousePressed
  • useNavigatorLanguage
  • useNetwork
  • useOnline
  • usePageLeave
  • useParallax
  • usePointer
  • usePointerSwipe
  • useScroll
  • useScrollLock
  • useSpeechRecognition
  • useSpeechSynthesis
  • useSwipe
  • useTextSelection
  • useUserMedia
  • useInterval
  • useIntervalFn
  • useNow
  • useRafFn
  • useTimeout
  • useTimeoutFn
  • useTimestamp
  • useTransition
  • createGlobalState
  • createInjectionState
  • createSharedComposable
  • useAsyncState
  • useDebouncedRefHistory
  • useLocalStorage
  • useManualRefHistory
  • useRefHistory
  • useSessionStorage
  • useStorage
  • useStorageAsync
  • useThrottledRefHistory
  • useActiveElement
  • useDocumentVisibility
  • useDraggable
  • useDropZone
  • useElementBounding
  • useElementSize
  • useElementVisibility
  • useIntersectionObserver
  • useMouseInElement
  • useMutationObserver
  • useResizeObserver
  • useWindowFocus
  • useWindowScroll
  • useWindowSize
  • computedInject
  • templateRef
  • tryOnBeforeMount
  • tryOnBeforeUnmount
  • tryOnMounted
  • tryOnScopeDispose
  • tryOnUnmounted
  • unrefElement
  • useCurrentElement
  • useMounted
  • useTemplateRefsList
  • useVirtualList
  • useVModel
  • useVModels
  • until
  • watchArray
  • watchAtMost
  • watchDebounced
  • watchIgnorable
  • watchOnce
  • watchPausable
  • watchThrottled
  • watchTriggerable
  • watchWithFilter
  • whenever
  • useEventSource
  • useFetch
  • useWebSocket
  • computedAsync
  • computedEager
  • computedWithControl
  • createEventHook
  • createUnrefFn
  • extendRef
  • get
  • isDefined
  • logicAnd
  • logicNot
  • logicOr
  • makeDestructurable
  • reactify
  • reactifyObject
  • reactiveComputed
  • reactiveOmit
  • reactivePick
  • refAutoReset
  • refDebounced
  • refDefault
  • refThrottled
  • refWithControl
  • resolveRef
  • resolveUnref
  • set
  • syncRef
  • syncRefs
  • toReactive
  • toRefs
  • useAsyncQueue
  • useBase64
  • useCached
  • useClamp
  • useConfirmDialog
  • useCounter
  • useCycleList
  • useDateFormat
  • useDebounceFn
  • useEventBus
  • useLastChanged
  • useMemoize
  • useOffsetPagination
  • useStepper
  • useThrottleFn
  • useTimeoutPoll
  • useToggle
  • useTimeAgo
  • useWebWorker
  • useWebWorkerFn
  • useIpcRenderer
  • useIpcRendererInvoke
  • useIpcRendererOn
  • useZoomFactor
  • useZoomLevel
  • useAuth
  • useFirestore
  • useRTDB
  • createHead
  • useHead
  • useAsyncValidator
  • useAxios
  • useChangeCase
  • useCookies
  • useDrauu
  • useFocusTrap
  • useFuse
  • useJwt
  • useNProgress
  • useQRCode
  • useElementStyle
  • useElementTransform
  • useMotion
  • useMotionProperties
  • useMotionVariants
  • useSpring
  • useRouteHash
  • useRouteParams
  • useRouteQuery
  • from
  • toObserver
  • useObservable
  • useSubject
  • useSubscription
  • createSchemaOrg
  • useSchemaOrg
  • useSound

@antfu antfu marked this pull request as ready for review July 8, 2022 05:39
@antfu
Copy link
Member Author

antfu commented Jul 8, 2022

I will merge it for now. We could handle the leftovers later.

@antfu antfu merged commit a9ccce4 into next Jul 8, 2022
@antfu antfu deleted the feat/use-maybe-computed-ref branch July 8, 2022 05:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

8 participants