mirror of
https://github.com/jaandrle/deka-dom-el
synced 2024-11-22 07:49:38 +01:00
📝 add comment to processReactiveAttribute
This commit is contained in:
parent
62a3b1ed35
commit
1cb1a8420c
@ -87,10 +87,11 @@ export const signals_config= {
|
|||||||
isTextContent(attributes){
|
isTextContent(attributes){
|
||||||
return typeOf(attributes)==="string" || ( isSignal(attributes) && typeOf(valueOfSignal(attributes))==="string" );
|
return typeOf(attributes)==="string" || ( isSignal(attributes) && typeOf(valueOfSignal(attributes))==="string" );
|
||||||
},
|
},
|
||||||
processReactiveAttribute(_, key, attrS, assignNth){
|
processReactiveAttribute(_, key, attrs, assignNth){
|
||||||
if(!isSignal(attrS)) return attrS;
|
//TODO DOC: once the signal is used as attribute, there is no reason to use assign again (if for some reason needed, use imperative listeners clear with `S.clear`)
|
||||||
addSignalListener(attrS, attr=> assignNth([ key, attr ]));
|
if(!isSignal(attrs)) return attrs;
|
||||||
return attrS();
|
addSignalListener(attrs, attr=> assignNth([ key, attr ]));
|
||||||
|
return attrs();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user