marko/runtime/vdom/VDocumentFragment.js
2017-03-28 11:02:12 -06:00

35 lines
777 B
JavaScript

var VNode = require('./VNode');
var inherit = require('raptor-util/inherit');
var extend = require('raptor-util/extend');
function VDocumentFragmentClone(other) {
extend(this, other);
this.$__parentNode = null;
this.$__nextSibling = null;
}
function VDocumentFragment(documentFragment) {
this.$__VNode(null /* childCount */);
this.namespaceURI = null;
}
VDocumentFragment.prototype = {
$__nodeType: 11,
$__DocumentFragment: true,
$__cloneNode: function() {
return new VDocumentFragmentClone(this);
},
$__actualize: function(doc) {
return doc.createDocumentFragment();
}
};
inherit(VDocumentFragment, VNode);
VDocumentFragmentClone.prototype = VDocumentFragment.prototype;
module.exports = VDocumentFragment;