Same as https://github.com/facebook/react/issues/10103, but for the server renderer. You can look at implementation in https://github.com/facebook/react/pull/11168 and do something very similar in `ReactPartialRenderer.js`.
cancelWorkTimer(workInProgress);
    
    
    switch (workInProgress.tag) {
      case HostRoot:
        pushHostRootContext(workInProgress);
        break;
      case ClassComponent:
        pushContextProvider(workInProgress);
        break;
      case HostPortal:
        pushHostContainer(
          workInProgress,
          workInProgress.stateNode.containerInfo,
        );
        break;
    }
    
    
    return null;
  }
  
  function memoizeProps(workInProgress: Fiber, nextProps: any) {