This repository was archived by the owner on Jan 24, 2019. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +12
-7
lines changed Expand file tree Collapse file tree 2 files changed +12
-7
lines changed Original file line number Diff line number Diff line change 2
2
$js - asynchronous module definition framework
3
3
or just simple lightweight javascript dependencies manager
4
4
5
- @version 3.2
5
+ @version 3.3
6
6
@link http://github.com/redcatphp/js/
7
7
@author Jo Surikat <jo@surikat.pro>
8
8
@website http://redcatphp.com
508
508
}
509
509
}
510
510
}
511
+ el . $js = o ;
511
512
var loadModuleDomElement = function ( ) {
512
513
var
513
514
func = $js . module ( module ) ,
774
775
return $js . invokeArray ( mod , args ) ;
775
776
} ;
776
777
js . paramsReflection = paramsReflection ;
778
+ js . moduleDomNs = 'js' ;
779
+ js . moduleDomPath = 'js.module.dom/' ;
777
780
js . moduleDom = function ( prefixPath , attrNs ) {
778
781
if ( ! prefixPath )
779
- prefixPath = ' js.module.dom/' ;
782
+ prefixPath = $ js. moduleDomPath ;
780
783
if ( ! attrNs )
781
- attrNs = 'js' ;
784
+ attrNs = $js . moduleDomNs ;
782
785
var all = document . getElementsByTagName ( '*' ) ;
783
786
for ( var i = 0 ; i < all . length ; i ++ ) {
784
- var js = all [ i ] . getAttribute ( attrNs ) ;
785
- if ( js ) {
786
- moduleDomElement ( prefixPath + js , all [ i ] , attrNs ) ;
787
+ if ( ! all [ i ] . $js ) {
788
+ var js = all [ i ] . getAttribute ( attrNs ) ;
789
+ if ( js ) {
790
+ moduleDomElement ( prefixPath + js , all [ i ] , attrNs ) ;
791
+ }
787
792
}
788
793
}
789
794
} ;
You can’t perform that action at this time.
0 commit comments