code: function debugDeepElementOrInstance(
    instance: React.Element<any> | ?ReactTestRendererJSON,
    message?: any = ''
  ) {
    try {
      // We're assuming React.Element<any> here and fallback to
      // rendering ?ReactTestRendererJSON
      // $FlowFixMe
      const { toJSON } = render(instance);
      if (message) {
        console.log(`${message}\n\n`, format(toJSON()));
      } else {
        console.log(format(toJSON()));
      }
    } catch (e) {
      // $FlowFixMe
      debugDeep(instance);
    }
  }
docs: Log pretty-printed deep test component instance