ソースを参照

Add a comment about why we are using realize immediately

Steven Silvester 8 年 前
コミット
be4f26e92f
1 ファイル変更4 行追加0 行削除
  1. 4 0
      src/common/dialog.ts

+ 4 - 0
src/common/dialog.ts

@@ -540,6 +540,10 @@ namespace Dialog {
      */
     createButtonNode(button: IButton): HTMLElement {
       let className = this.createItemClass(button);
+      // We use realize here instead of creating
+      // nodes with document.createElement as a
+      // shorthand, and only because this is not
+      // called often.
       return VirtualDOM.realize(
         h.button({ className },
               this.renderIcon(button),