text: /**
   * createElement
   * 
   * const element = (
      <div id="foo">
        <a>bar</a>
        <b />
      </div>
    )
  
    const element = React.createElement(
      "div",
      { id: "foo" },
      React.createElement("a", null, "bar"),
      React.createElement("b")
    )
   */
  
  function createElement(type, props, ...children) {
    return {
      type,
      props: {
        ...props,
        children: children.map(child =>
          typeof child === "object"
            ? child
            : createTextElement(child)
        ),
      },
    }
  }
  
  // 文本
  function createTextElement(text) {
    return {
      type: "TEXT_ELEMENT",
      props: {
        nodeValue: text,
        children: [],
      },
    }
  }
  