Skip to content

⬅️ Back to Table of Contents

📄 useLastChanged

📊 Analysis Summary

Metric Count
🔧 Functions 1
📦 Imports 7
🟢 Vue Composition API 1
📐 Interfaces 1
📑 Type Aliases 1

📚 Table of Contents

🛠️ File Location:

📂 packages/shared/useLastChanged/index.ts

📦 Imports

Name Source
ShallowRef vue
WatchOptions vue
WatchSource vue
shallowReadonly vue
shallowRef vue
watch vue
timestamp ../utils

Vue Composition API

Name Type Reactive Variables Composables
watch watch none none

Functions

useLastChanged(source: WatchSource, options: UseLastChangedOptions<false>): Readonly<ShallowRef<number | null>>

Records the timestamp of the last change

See: https://vueuse.org/useLastChanged

Raw JSDoc
/**
 * Records the timestamp of the last change
 *
 * @see https://vueuse.org/useLastChanged
 */
Code
export function useLastChanged(source: WatchSource, options?: UseLastChangedOptions<false>): Readonly<ShallowRef<number | null>>

Interfaces

UseLastChangedOptions<Immediate extends boolean, InitialValue extends number | null | undefined = undefined>

Interface Code
export interface UseLastChangedOptions<
  Immediate extends boolean,
  InitialValue extends number | null | undefined = undefined,
> extends WatchOptions<Immediate> {
  initialValue?: InitialValue
}

Properties

Name Type Optional Description
initialValue InitialValue not shown

Type Aliases

UseLastChangedReturn

type UseLastChangedReturn = Readonly<ShallowRef<number | null>> | Readonly<ShallowRef<number>>;

Generated by Syntax Scribe