浏览代码

Merge pull request #820 from yuler/master

Remove useless callbak in `listenForNewUninitializedComponentsAtRunTi…
Caleb Porzio 4 年之前
父节点
当前提交
1eac912615
共有 1 个文件被更改,包括 2 次插入4 次删除
  1. 2 4
      src/index.js

+ 2 - 4
src/index.js

@@ -31,9 +31,7 @@ const Alpine = {
             })
         })
 
-        this.listenForNewUninitializedComponentsAtRunTime(el => {
-            this.initializeComponent(el)
-        })
+        this.listenForNewUninitializedComponentsAtRunTime()
     },
 
     discoverComponents: function (callback) {
@@ -54,7 +52,7 @@ const Alpine = {
             })
     },
 
-    listenForNewUninitializedComponentsAtRunTime: function (callback) {
+    listenForNewUninitializedComponentsAtRunTime: function () {
         const targetNode = document.querySelector('body');
 
         const observerOptions = {