Skip to content

Releases: shysolocup/stews

1.3.0

10 Mar 04:53
06dcc82
Compare
Choose a tag to compare

The Cleaner Update ✨ 🍲

Stews v1.3.0

holy fuck this has been a big and very annoying update to make like so big and annoying I started it like a week ago

here are the new changes additions and new things that are coming in the stews 1.3.0 update

Cleaner Fetching

Now instead of having to use fetch() you can use these!

also fetch() still exists but this is cool;

let list = new Stew( ["a", "b", "c", "d"] );
let pair = new Stew( {"key": "value", "other key": "other value"} );

list[0]; // "a"
list['a']; // "a"
list.a; // "a"

pair[0]; // "value"
pair['key']; // "value"
pair.key; // "value"

Cleaner Setting

Now instead of having to use set() you can just do it the old fashioned way!

let list = new Stew( ["e", "b", "f", "d"] );
let pair = new Stew( {"key": "value5", "key2": "other OTHER value"} );

list[0] = "a";
list.f = "c";

// ["a", "b", "c", "d"]

pair[0] = "value";
pair.key2 = "other value";

// {key: "value", key2: "other value"}

Cleaner Deleting

Now instead of having to use delete() you can just do it once again the old fashioned way!

let list = new Stew( ["a", "e", "b", "f", "c"] );
let pair = new Stew( {"key": "value", "key2": "other value", "key3": "other OTHER value"} );

delete list[1];
delete list.f;

// ["a", "b", "c"]

delete pair[1];
delete pair.key3;

// {key: "value"}

KeyOf, ValueOf, and EntryOf Functions!

Now instead of just indexOf there is keyOf, valueOf, and entryOf for you to use!


Front and Back Functions!

Front

gets the first entry in a stew/soup

Alias first()

Back

gets the last entry in a stew/soup

Alias last()


Updated documentation

The new documentation should be fully up to date for 1.3.0 if you want to see it go here


Misc

  • Updated filter() and similar functions to have key, value, and index parameters instead of just stuff
  • Added rename() which lets you rename a key. Stew/Soup.rename(<old>, <new>);
  • Changed types to be only list and pair so they can be made faster
  • Updated stringify() to work with lists
  • Removed parse() bc it's stupid
  • Added isStew() and isSoup()
  • NUMEROUS bug fixes and stupid changes

1.2.2

03 Mar 15:33
8afa0d2
Compare
Choose a tag to compare

Stews v1.2.2 🍲

  • Added mapify() alias toMap() and setify() alias toSet() to turn stews/soups into maps and sets
  • Updated pour() to have an optional type and joiner:
// arrays
let array = new Stew( [1, 2, 3, 4] );

array.pour(); // [1, 2, 3, 4]
array.pour(Set); // Set(4) { 1, 2, 3, 4 }
array.pour(String); // "1234"
array.pour(String, ' '); // "1 2 3 4"
array.pour(Stew); // would turn it into a stew
array.pour(Soup); // would turn it into a soup
// objects
let object = new Stew([ ["a", 1], ["b", 2] ]);

object.pour(); // [ ["a", 1], ["b", 2] ]
object.pour(Set); // Set(2) { ["a", 1], ["b", 2] }
object.pour(Object); // {"a": 1, "b": 2}
object.pour(Map); // Map(2) { 'a' => 1, 'b' => 2 }
object.pour(Stew); // would turn it into a stew
object.pour(Soup); // would turn it into a soup

1.2.1

02 Mar 14:29
89d6a20
Compare
Choose a tag to compare

Stews v1.2.1 🍲

  • fixed a bug with reversing stews

1.2.0

01 Mar 20:47
576dd95
Compare
Choose a tag to compare

The Strings and Sorts Update! 🧵 🍲

Stews v1.2.0

  • Removed brew() for soups and stews and replaced it with pour() to avoid confusion with the new brew function
  • Added support for strings so that you don't have to manually split them
  • Added sort()
  • Added reverse()
  • Replaced the main some() with swig() and made some() an alias
  • Added new brew() function
  • Added a new way to create new stews/soups with a certain type:
// turns into an object/map
new Stew(Object)
new Stew(Map)

// turns into an array/set
new Stew(String)
new Stew(Array)
new Stew(Set)

// depends on what type the stew/soup is
new Stew(Stew)
new Stew(Soup)

1.1.2

01 Mar 16:37
dd1dee3
Compare
Choose a tag to compare

I forgor to add brew() mb lol

1.1.1

01 Mar 15:55
a5f4b69
Compare
Choose a tag to compare

Stews v1.1.1 🍲

  • Minor bug fixes
  • Added the ability to make new soups/stews from another soup/stew
  • added Stew.from() and Soup.from()
  • Added brew() alias for stir()
  • Added isList() and isPair()
  • Added map()
  • Added some()
  • Added slice()

1.1.0

28 Feb 19:33
0f7aec4
Compare
Choose a tag to compare

THE SOUP UPDATE!! 🙏 🍲

Stews v1.1.0

1.0.2

28 Feb 08:24
3fcb3f2
Compare
Choose a tag to compare

fixed a bug with fetching

1.0.1

27 Feb 23:35
2ab5735
Compare
Choose a tag to compare

hopefully fixed everything 🙏

1.0.0

27 Feb 23:15
82ac4af
Compare
Choose a tag to compare

released