Home / Function/ triggerRef() — vue Function Reference

triggerRef() — vue Function Reference

Architecture documentation for the triggerRef() function in ref.ts from the vue codebase.

Entity Profile

Dependency Diagram

graph TD
  becf88af_0d85_7b6b_615d_62e92fb82199["triggerRef()"]
  066df273_90c0_35dd_cd79_8e43c3f6c8ba["notify()"]
  becf88af_0d85_7b6b_615d_62e92fb82199 -->|calls| 066df273_90c0_35dd_cd79_8e43c3f6c8ba
  style becf88af_0d85_7b6b_615d_62e92fb82199 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

src/v3/reactivity/ref.ts lines 77–91

export function triggerRef(ref: Ref) {
  if (__DEV__ && !ref.dep) {
    warn(`received object is not a triggerable ref.`)
  }
  if (__DEV__) {
    ref.dep &&
      ref.dep.notify({
        type: TriggerOpTypes.SET,
        target: ref,
        key: 'value'
      })
  } else {
    ref.dep && ref.dep.notify()
  }
}

Domain

Subdomains

Calls

Frequently Asked Questions

What does triggerRef() do?
triggerRef() is a function in the vue codebase.
What does triggerRef() call?
triggerRef() calls 1 function(s): notify.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free