Comparing version 0.0.8 to 0.0.9
@@ -78,3 +78,6 @@ function _define_property(obj, key, value) { | ||
add(items, at) { | ||
if (at === undefined) { | ||
if (at !== undefined && (at < 0 || at >= this.length)) { | ||
throw TypeError("'at' exceeds the range of the itemViews array."); | ||
} | ||
if (at === undefined || at === this.length) { | ||
this.appendAll(items); | ||
@@ -86,3 +89,3 @@ } else if (at === 0) { | ||
this.data.splice(at, 0, ...items); | ||
this._itemViews[at].element().before(...itemViews.map((view)=>view.element())); | ||
this._itemViews[at].element().before(...itemViews.map((view)=>view.render())); | ||
this._itemViews.splice(at, 0, ...itemViews); | ||
@@ -89,0 +92,0 @@ } |
@@ -100,3 +100,6 @@ "use strict"; | ||
add(items, at) { | ||
if (at === undefined) { | ||
if (at !== undefined && (at < 0 || at >= this.length)) { | ||
throw TypeError("'at' exceeds the range of the itemViews array."); | ||
} | ||
if (at === undefined || at === this.length) { | ||
this.appendAll(items); | ||
@@ -108,3 +111,3 @@ } else if (at === 0) { | ||
this.data.splice(at, 0, ...items); | ||
this._itemViews[at].element().before(...itemViews.map((view)=>view.element())); | ||
this._itemViews[at].element().before(...itemViews.map((view)=>view.render())); | ||
this._itemViews.splice(at, 0, ...itemViews); | ||
@@ -111,0 +114,0 @@ } |
{ | ||
"name": "rune-ts", | ||
"version": "0.0.8", | ||
"version": "0.0.9", | ||
"description": "Rune Core Library", | ||
@@ -5,0 +5,0 @@ "engines": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
208124
3359