src/lib/component.js
function postpatch(oldVnode, vnode) {
  const oldData = oldVnode.data
  const newData = vnode.data

  // Server side rendering: Reconcilating with a server-rendered node will have skipped calling insert()
  if (!oldData.component) {
    insert(vnode)
  }

  // oldData wouldn't have a component reference set if it came from the server (it's first set in insert())
  const component = oldData.component || newData.component
  const oldProps = component.props
  const newProps = newData.component.props

  // Update the original component with any property that may have changed during this render pass
  component.props = newProps

  newData.component = component

  // If the props changed, render immediately as we are already
  // in the render context of our parent
  if (!shallowEqual(oldProps, newProps)) {

    component.lifecycle.propsChanging = true
    component.lifecycle.propsChanged(newProps)
    component.lifecycle.propsChanging = false

    renderComponentNow(component)
  }
}
function postpatch(oldVnode, vnode) {
  const oldData = oldVnode.data
  const newData = vnode.data

  // Server side rendering: Reconcilating with a server-rendered node will have skipped calling insert()
  if (!oldData.component) {
    insert(vnode)
  }

  // oldData wouldn't have a component reference set if it came from the server (it's first set in insert())
  const component = oldData.component || newData.component
  const oldProps = component.props
  const newProps = newData.component.props

  // Update the original component with any property that may have changed during this render pass
  component.props = newProps

  newData.component = component

  // If the props changed, render immediately as we are already
  // in the render context of our parent
  if (!shallowEqual(oldProps, newProps)) {

    component.lifecycle.propsChanging = true
    component.lifecycle.propsChanged(newProps)
    component.lifecycle.propsChanging = false

    renderComponentNow(component)
  }
}
function postpatch ( oldVnode , vnode ) { const oldData = oldVnode . data const newData = vnode . data // Server side rendering: Reconcilating with a server-rendered node will have skipped calling insert() if ( ! oldData . component ) { insert ( vnode ) } // oldData wouldn't have a component reference set if it came from the server (it's first set in insert()) const component = oldData . component || newData . component const oldProps = component . props const newProps = newData . component . props // Update the original component with any property that may have changed during this render pass component . props = newProps newData . component = component // If the props changed, render immediately as we are already // in the render context of our parent if ( ! shallowEqual ( oldProps , newProps ) ) { component . lifecycle . propsChanging = true component . lifecycle . propsChanged ( newProps ) component . lifecycle . propsChanging = false renderComponentNow ( component ) } }
Called on every parent re-render, this is where the props passed by the component's parent may have changed.
Called on every parent re - render this is where the props passed by the component s parent may have changed .