@alexgyver/component 1.1.1 → 1.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Component.js +4 -0
- package/package.json +1 -1
package/Component.js
CHANGED
|
@@ -80,6 +80,10 @@ export class Component {
|
|
|
80
80
|
* @returns {Node}
|
|
81
81
|
*/
|
|
82
82
|
static config(el, data, ns = false) {
|
|
83
|
+
if (Array.isArray(el)) {
|
|
84
|
+
el.forEach(e => Component.config(e, data, ns));
|
|
85
|
+
return;
|
|
86
|
+
}
|
|
83
87
|
if (!(el instanceof Node) || (typeof data !== 'object')) return el;
|
|
84
88
|
const context = data.context;
|
|
85
89
|
|