Remove more unused knockout code

This commit is contained in:
djmaze 2020-10-28 13:58:37 +01:00
parent d0f5828751
commit ff6fb41812
14 changed files with 224 additions and 399 deletions

View file

@ -82,7 +82,7 @@ ko.utils = (() => {
moveCleanedNodesToContainerElement: nodes => {
// Ensure it's a real array, as we're about to reparent the nodes and
// we don't want the underlying collection to change while we're doing that.
var nodesArray = ko.utils.makeArray(nodes);
var nodesArray = [...nodes];
var templateDocument = (nodesArray[0] && nodesArray[0].ownerDocument) || document;
var container = templateDocument.createElement('div');
@ -206,9 +206,7 @@ ko.utils = (() => {
toggleDomNodeCssClass: toggleDomNodeCssClass,
setTextContent: (element, textContent) =>
element.textContent = ko.utils.unwrapObservable(textContent) || "",
makeArray: arrayLikeObject => Array['from'](arrayLikeObject)
element.textContent = ko.utils.unwrapObservable(textContent) || ""
}
})();