Releases: shysolocup/stews
Releases · shysolocup/stews
1.4.3
Stews v1.4.3 🍲
- FINALLY FIXED THE DELETE BUG
- Added find() to get an array of all indexes for a key
- Added lastIndexOf()
- Added chug()
- Replaced multiDelete() with the superior scoop()
- Removed includesFor() and added it into includes() and includesValue()
- Added alias findFirst() for indexOf()
- Fixed the doc's description for swig() and chug() to be more specific about it's purpose
- Fixed some other random documentation issues
1.4.2
Stews v1.4.2 🍲
- Fixed a bug with soup deleting hopefully
- Updated includes to allow multi checking
- Updated keyOf() to look for values instead of keys
- Added indexOfKey() alias for indexOf()
- Added edit() alias for set()
- Added indexOfValue()
- Added includesValue()
- Added multiDelete()
- Added a number symbol primitive
1.4.1
1.4.0
Random Stuff Update 🐢 🍲
Stews 1.4.0
This update adds a few cool things that I thought were big enough to make a full update for
Stew/Soup.random
Random is now built inside stews and soups so now you can do things like this:
stew.random.choice();
stew.random.index();
soup.random.choice();
soup.random.index();
JSON Dumping
Dump lets you put your stew or soup into a JSON file
stew.dump("./file.json"); // without indent
stew.dump("./file.json", null, 4); // with indent
soup.dump("./file.json"); // without indent
soup.dump("./file.json", null, 4); // with indent
Symbol Primitive and Iterator
Added symbol stuff to make for of and other stuff work
Primitive
let list = new Stew( [1, 2, 3, 4] );
let pair = new Stew( {"key0": "value0", "key1": "value1"} );
console.log(`${list}`); // "1,2,3,4"
console.log(`${pair}`); // "key0,value0,key1,value1"
Iterator
let list = new Stew( ["a", "b", "c", "d"] );
let pair = new Stew( {"key0": "value0", "key1": "value1"} );
for ( [value, index] of list ) {
console.log(value, index);
}
for ( [key, value, index] of pair) {
console.log(key, value, index);
}
Properties
Lets you get the properties of a stew/soup including the names, descriptors, and methods
object.properties.names; // returns an array of the property names including functions
object.props.descriptors; // returns an object with all of the data for the stuff including functions
object.props.methods; // returns an object with all of the functions
1.3.6
1.3.5
Stews v1.3.5 🍲
- Added object.deleteDupes() for soups
- Added aliases rem() and del() for delete()
- Updated readme file
1.3.4
Stews v1.3.4
- Added Stew.fromEntries() and Soup.fromEntries()
- Added Stew.parse() and Soup.parse()
- Added random.number() alias for random.int()
1.3.3
Stews v1.3.3
- Removed the change logs folder because it was a pain to update constantly replaced with the releases page
- Added offset arguments for front() and back()
- Added includesFor()
- Readded random class
const { random } = require('stews');
1.3.2
bug where you couldn't delete a part of a soup with an index is fixed now I rlly needed this patched bc it's stupid
1.3.1
fixed a bug with setting hopefully