Skip to content
This repository has been archived by the owner on Mar 13, 2018. It is now read-only.

Commit

Permalink
minor Observer changes
Browse files Browse the repository at this point in the history
  • Loading branch information
sorvell committed Jan 18, 2014
1 parent f3be8f1 commit 403b6c1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
1 change: 1 addition & 0 deletions src/HTMLImports.js
Original file line number Diff line number Diff line change
Expand Up @@ -246,5 +246,6 @@ scope.hasNative = hasNative;
scope.useNative = useNative;
scope.whenImportsReady = whenImportsReady;
scope.IMPORT_LINK_TYPE = IMPORT_LINK_TYPE;
scope.isImportLoaded = isImportLoaded;

})(window.HTMLImports);
7 changes: 3 additions & 4 deletions src/Observer.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,8 @@ function addedNodes(nodes) {
}
}

// TODO(sorvell): need x-platform matches
function shouldLoadNode(node) {
return node.matches(importer.preloadSelectors);
return matches.call(node, importer.preloadSelectors);
}

var observer = new MutationObserver(handler);
Expand All @@ -54,8 +53,8 @@ function canParse(node) {
return nextImportToParse(doc) === node;
}

function nextImportToParse(doc) {

function nextImportToParse() {
//doc.querySelectorAll(importSelector)
}


Expand Down

0 comments on commit 403b6c1

Please sign in to comment.