Stew.clear() - shysolocup/stews GitHub Wiki
removes every entry
type: Function
list: | pair: |
const { Stew } = require('stews');
let arr = new Stew([ "a", "b" ]);
console.log(arr);
arr.clear();
console.log(arr); |
const { Stew } = require('stews');
let obj = new Stew({ key1: "val1", key2: "val2" });
console.log(obj);
obj.clear();
console.log(obj); |
Stew(2) [ "a", "b" ] // before
Stew(0) [ ] // after |
Stew(2) { key1: "val1", key2: "val2" } // before
Stew(0) { } // after |