File tree 1 file changed +3
-5
lines changed
src/StimulusBundle/assets/src 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -64,7 +64,9 @@ class StimulusLazyControllerHandler {
64
64
}
65
65
66
66
private lazyLoadExistingControllers ( element : Element ) {
67
- this . queryControllerNamesWithin ( element ) . forEach ( ( controllerName ) => this . loadLazyController ( controllerName ) ) ;
67
+ Array . from ( element . querySelectorAll ( `[${ controllerAttribute } ]` ) ) . flatMap ( extractControllerNamesFrom ) . forEach (
68
+ ( controllerName ) => this . loadLazyController ( controllerName )
69
+ ) ;
68
70
}
69
71
70
72
private async loadLazyController ( name : string ) {
@@ -106,10 +108,6 @@ class StimulusLazyControllerHandler {
106
108
childList : true ,
107
109
} ) ;
108
110
}
109
-
110
- private queryControllerNamesWithin ( element : Element ) : string [ ] {
111
- return Array . from ( element . querySelectorAll ( `[${ controllerAttribute } ]` ) ) . flatMap ( extractControllerNamesFrom ) ;
112
- }
113
111
}
114
112
115
113
function registerController ( name : string , controller : ControllerConstructor , application : Application ) {
You can’t perform that action at this time.
0 commit comments