@microsoft/teams.common
Version:
<p> <a href="https://www.npmjs.com/package/@microsoft/teams.common" target="_blank"> <img src="https://img.shields.io/npm/v/@microsoft/teams.common/latest" /> </a> <a href="https://www.npmjs.com/package/@microsoft/teams.common?activeTa
34 lines (33 loc) • 618 B
JavaScript
class ListLocalStorage {
_list;
constructor(data = []) {
this._list = [...data];
}
get(key) {
return this._list[key];
}
set(key, value) {
this._list[key] = value;
}
delete(key) {
this._list.splice(key, 1);
}
push(value) {
this._list.push(value);
}
pop() {
return this._list.pop();
}
values() {
return [...this._list];
}
length() {
return this._list.length;
}
where(predicate) {
return this._list.filter(predicate);
}
}
export { ListLocalStorage };
//# sourceMappingURL=list-local-storage.mjs.map
//# sourceMappingURL=list-local-storage.mjs.map