switch to doneEach and cache #main dom

This commit is contained in:
Leopoldthecoder 2017-03-07 11:30:09 +08:00
commit 9c54bafae4
8 changed files with 27 additions and 33 deletions

View file

@ -161,7 +161,7 @@ function getNode (el, noCache) {
if ( noCache === void 0 ) noCache = false;
if (typeof el === 'string') {
el = noCache ? find(el) : (cacheNode[el] || find(el));
el = noCache ? find(el) : (cacheNode[el] || (cacheNode[el] = find(el)));
}
return el