message: Refactor renderer
diff: import * as React from 'react';
  import * as renderers from './renderers';
  -export const renderer = async (jsx: React.ReactElement<any>) => {
  - const queue = [];
  -
  - const collectQueue = jsx => {
  +export const renderer = async (jsx: any) => {
  if (typeof jsx.type === 'function') {
  const result = jsx.type(jsx.props);
  - collectQueue(result);
  + await renderer(result);
  } else if (jsx.type === React.Fragment) {
  - React.Children.forEach(jsx.props.children, child => {
  - collectQueue(child);
  + React.Children.forEach(jsx.props.children, async child => {
  + await renderer(child);
  });
  } else if (renderers[jsx.type]) {
  - queue.push(jsx);
  + await renderers[jsx.type](jsx.props);
  }
  if (!renderers[jsx.type] && React.isValidElement<{ children: any }>(jsx) && jsx.props.children) {
  - collectQueue(jsx.props.children);
  - }
  - };
  - collectQueue(jsx);
  -
  - for (const item of queue) {
  - await renderers[item.type](item.props);
  + await renderer(jsx.props.children);
  }
  };
  