From 2ac5d3eae23aee36676a4a83401fe1a2af768f77 Mon Sep 17 00:00:00 2001
From: Cam <21029087+cxmeel@users.noreply.github.com>
Date: Mon, 11 Mar 2024 17:00:10 +0000
Subject: [PATCH 01/43] Remove roblox/testez
---
.gitmodules | 3 -
.husky/pre-commit | 5 -
.prettierrc.json | 14 -
.vscode/launch.json | 15 -
.vscode/scripts/run-tests.ps1 | 8 -
.vscode/settings.json | 21 +-
LICENSE | 2 +-
foreman.toml | 6 -
modules/testez | 1 -
package-lock.json | 1654 ---------------------------------
selene.toml | 2 +-
testez.toml | 67 --
12 files changed, 10 insertions(+), 1788 deletions(-)
delete mode 100644 .gitmodules
delete mode 100644 .husky/pre-commit
delete mode 100644 .prettierrc.json
delete mode 100644 .vscode/launch.json
delete mode 100644 .vscode/scripts/run-tests.ps1
delete mode 100644 foreman.toml
delete mode 160000 modules/testez
delete mode 100644 package-lock.json
delete mode 100644 testez.toml
diff --git a/.gitmodules b/.gitmodules
deleted file mode 100644
index c8f8c6f..0000000
--- a/.gitmodules
+++ /dev/null
@@ -1,3 +0,0 @@
-[submodule "modules/testez"]
- path = modules/testez
- url = https://github.com/roblox/testez
diff --git a/.husky/pre-commit b/.husky/pre-commit
deleted file mode 100644
index ece6a97..0000000
--- a/.husky/pre-commit
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/usr/bin/env sh
-. "$(dirname -- "$0")/_/husky.sh"
-
-stylua --check src/
-selene src/
diff --git a/.prettierrc.json b/.prettierrc.json
deleted file mode 100644
index db44278..0000000
--- a/.prettierrc.json
+++ /dev/null
@@ -1,14 +0,0 @@
-{
- "arrowParens": "always",
- "bracketSameLine": false,
- "bracketSpacing": true,
- "endOfLine": "auto",
- "jsxSingleQuote": false,
- "printWidth": 80,
- "quoteProps": "consistent",
- "semi": false,
- "singleQuote": false,
- "tabWidth": 2,
- "trailingComma": "es5",
- "useTabs": false
-}
diff --git a/.vscode/launch.json b/.vscode/launch.json
deleted file mode 100644
index b63a2c7..0000000
--- a/.vscode/launch.json
+++ /dev/null
@@ -1,15 +0,0 @@
-{
- // Use IntelliSense to learn about possible attributes.
- // Hover to view descriptions of existing attributes.
- // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
- "version": "0.2.0",
- "configurations": [
- {
- "name": "PowerShell: Run Tests",
- "type": "PowerShell",
- "request": "launch",
- "script": "${workspaceFolder}/.vscode/scripts/run-tests.ps1",
- "cwd": "${workspaceFolder}"
- }
- ]
-}
diff --git a/.vscode/scripts/run-tests.ps1 b/.vscode/scripts/run-tests.ps1
deleted file mode 100644
index 8a3fe5a..0000000
--- a/.vscode/scripts/run-tests.ps1
+++ /dev/null
@@ -1,8 +0,0 @@
-$FILE_NAME = ".\test-place.rbxl"
-$TEST_PROJ = ".\test.project.json"
-$TEST_RUNR = ".\TestRunner.server.lua"
-
-aftman install
-rojo build "$TEST_PROJ" -o "$FILE_NAME"
-run-in-roblox --place "$FILE_NAME" --script "$TEST_RUNR"
-Remove-Item "$FILE_NAME" -Force -ErrorAction SilentlyContinue
diff --git a/.vscode/settings.json b/.vscode/settings.json
index 52d7ad7..669c6bd 100644
--- a/.vscode/settings.json
+++ b/.vscode/settings.json
@@ -1,20 +1,15 @@
{
"[lua]": {
- "editor.defaultFormatter": "JohnnyMorganz.stylua"
+ "editor.defaultFormatter": "JohnnyMorganz.stylua",
+ "editor.formatOnSave": true,
+ "editor.formatOnPaste": true
},
- "[json]": {
- "editor.defaultFormatter": "esbenp.prettier-vscode"
+ "[luau]": {
+ "editor.defaultFormatter": "JohnnyMorganz.stylua",
+ "editor.formatOnSave": true,
+ "editor.formatOnPaste": true
},
"[typescript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
- },
- "editor.codeActionsOnSave": {
- "source.fixAll": true,
- "source.organizeImports": true
- },
- "editor.formatOnSave": true,
- "editor.formatOnPaste": true,
- "editor.formatOnType": true,
- "debug.toolBarLocation": "hidden",
- "files.eol": "\n"
+ }
}
diff --git a/LICENSE b/LICENSE
index 73cf3c4..5c4ae0b 100644
--- a/LICENSE
+++ b/LICENSE
@@ -1,6 +1,6 @@
MIT License
-Copyright (c) 2022 csqrl
+Copyright (c) 2024 cxmeel
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
diff --git a/foreman.toml b/foreman.toml
deleted file mode 100644
index 2c6763b..0000000
--- a/foreman.toml
+++ /dev/null
@@ -1,6 +0,0 @@
-[tools]
-rojo = { source = "rojo-rbx/rojo", version = "=7.1.1" }
-run-in-roblox = { source = "rojo-rbx/run-in-roblox", version = "=0.3.0" }
-wally = { source = "upliftgames/wally", version = "=0.3.1" }
-stylua = { source = "johnnymorganz/stylua", version = "=0.13.1" }
-selene = { source = "kampfkarren/selene", version = "=0.17.0" }
diff --git a/modules/testez b/modules/testez
deleted file mode 160000
index 4bcc719..0000000
--- a/modules/testez
+++ /dev/null
@@ -1 +0,0 @@
-Subproject commit 4bcc719877c9f2074b35877383e1f29dc996bf51
diff --git a/package-lock.json b/package-lock.json
deleted file mode 100644
index 0ef74a7..0000000
--- a/package-lock.json
+++ /dev/null
@@ -1,1654 +0,0 @@
-{
- "name": "@rbxts/sift",
- "version": "0.0.7",
- "lockfileVersion": 2,
- "requires": true,
- "packages": {
- "": {
- "name": "@rbxts/sift",
- "version": "0.0.7",
- "license": "MIT",
- "devDependencies": {
- "@rbxts/compiler-types": "^1.2.3-types.0",
- "@rbxts/types": "^1.0.515",
- "husky": "^8.0.0",
- "rbxts-transform-debug": "^1.0.0-rc.1",
- "rbxts-transform-env": "^1.0.0-rc.0",
- "roblox-ts": "^1.2.7",
- "typescript": "^4.3.5"
- }
- },
- "node_modules/@rbxts/compiler-types": {
- "version": "1.2.3-types.1",
- "resolved": "https://registry.npmjs.org/@rbxts/compiler-types/-/compiler-types-1.2.3-types.1.tgz",
- "integrity": "sha512-SXXIBazyJ7N6d2xcy471/kqZZpCv7EDOWrRJ45jcv3g00VQaZwYl4Elr10woqRloIblQanwJ7yUqGXAsWv7iuQ==",
- "dev": true
- },
- "node_modules/@rbxts/types": {
- "version": "1.0.591",
- "resolved": "https://registry.npmjs.org/@rbxts/types/-/types-1.0.591.tgz",
- "integrity": "sha512-72lPUo6ecDxwdL8MhAgyFZiNQ6+/8hSHZDW8IcP6IRdHKn4zq9ABwsQjeIsWuKSI/EgG6k9LrTAdcG9FDaxUYw==",
- "dev": true
- },
- "node_modules/@roblox-ts/luau-ast": {
- "version": "1.0.1",
- "resolved": "https://registry.npmjs.org/@roblox-ts/luau-ast/-/luau-ast-1.0.1.tgz",
- "integrity": "sha512-FTKP24O0EbGupOmfJ6UHpag0K597bCpN4veDP9N91hSsrhIIHV59xLYw/e97g6hmwqYBfxOCuAvuLvsR4C9aMw==",
- "dev": true
- },
- "node_modules/@roblox-ts/rojo-resolver": {
- "version": "1.0.2",
- "resolved": "https://registry.npmjs.org/@roblox-ts/rojo-resolver/-/rojo-resolver-1.0.2.tgz",
- "integrity": "sha512-491pyfdxA7cmhDlY23rQi1rEuLCl0mPeAOUQbd6XdiaZ461MMtj38lvn1f8SXd6ZoZ/S4cO0XQUcKEBDGMdM2Q==",
- "dev": true,
- "dependencies": {
- "ajv": "^8.6.3",
- "fs-extra": "^10.0.0"
- }
- },
- "node_modules/ajv": {
- "version": "8.11.0",
- "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.11.0.tgz",
- "integrity": "sha512-wGgprdCvMalC0BztXvitD2hC04YffAvtsUn93JbGXYLAtCUO4xd17mCCZQxUOItiBwZvJScWo8NIvQMQ71rdpg==",
- "dev": true,
- "dependencies": {
- "fast-deep-equal": "^3.1.1",
- "json-schema-traverse": "^1.0.0",
- "require-from-string": "^2.0.2",
- "uri-js": "^4.2.2"
- },
- "funding": {
- "type": "github",
- "url": "https://github.com/sponsors/epoberezkin"
- }
- },
- "node_modules/ansi-regex": {
- "version": "5.0.1",
- "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz",
- "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==",
- "dev": true,
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/ansi-styles": {
- "version": "4.3.0",
- "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
- "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
- "dev": true,
- "dependencies": {
- "color-convert": "^2.0.1"
- },
- "engines": {
- "node": ">=8"
- },
- "funding": {
- "url": "https://github.com/chalk/ansi-styles?sponsor=1"
- }
- },
- "node_modules/anymatch": {
- "version": "3.1.2",
- "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.2.tgz",
- "integrity": "sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg==",
- "dev": true,
- "dependencies": {
- "normalize-path": "^3.0.0",
- "picomatch": "^2.0.4"
- },
- "engines": {
- "node": ">= 8"
- }
- },
- "node_modules/binary-extensions": {
- "version": "2.2.0",
- "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz",
- "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==",
- "dev": true,
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/braces": {
- "version": "3.0.2",
- "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz",
- "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==",
- "dev": true,
- "dependencies": {
- "fill-range": "^7.0.1"
- },
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/chalk": {
- "version": "4.1.2",
- "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
- "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
- "dev": true,
- "dependencies": {
- "ansi-styles": "^4.1.0",
- "supports-color": "^7.1.0"
- },
- "engines": {
- "node": ">=10"
- },
- "funding": {
- "url": "https://github.com/chalk/chalk?sponsor=1"
- }
- },
- "node_modules/chokidar": {
- "version": "3.5.3",
- "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz",
- "integrity": "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==",
- "dev": true,
- "funding": [
- {
- "type": "individual",
- "url": "https://paulmillr.com/funding/"
- }
- ],
- "dependencies": {
- "anymatch": "~3.1.2",
- "braces": "~3.0.2",
- "glob-parent": "~5.1.2",
- "is-binary-path": "~2.1.0",
- "is-glob": "~4.0.1",
- "normalize-path": "~3.0.0",
- "readdirp": "~3.6.0"
- },
- "engines": {
- "node": ">= 8.10.0"
- },
- "optionalDependencies": {
- "fsevents": "~2.3.2"
- }
- },
- "node_modules/cliui": {
- "version": "7.0.4",
- "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz",
- "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==",
- "dev": true,
- "dependencies": {
- "string-width": "^4.2.0",
- "strip-ansi": "^6.0.0",
- "wrap-ansi": "^7.0.0"
- }
- },
- "node_modules/color-convert": {
- "version": "2.0.1",
- "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
- "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
- "dev": true,
- "dependencies": {
- "color-name": "~1.1.4"
- },
- "engines": {
- "node": ">=7.0.0"
- }
- },
- "node_modules/color-name": {
- "version": "1.1.4",
- "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
- "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
- "dev": true
- },
- "node_modules/colors": {
- "version": "1.4.0",
- "resolved": "https://registry.npmjs.org/colors/-/colors-1.4.0.tgz",
- "integrity": "sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA==",
- "dev": true,
- "engines": {
- "node": ">=0.1.90"
- }
- },
- "node_modules/cross-spawn": {
- "version": "7.0.3",
- "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz",
- "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==",
- "dev": true,
- "dependencies": {
- "path-key": "^3.1.0",
- "shebang-command": "^2.0.0",
- "which": "^2.0.1"
- },
- "engines": {
- "node": ">= 8"
- }
- },
- "node_modules/dotenv": {
- "version": "8.6.0",
- "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-8.6.0.tgz",
- "integrity": "sha512-IrPdXQsk2BbzvCBGBOTmmSH5SodmqZNt4ERAZDmW4CT+tL8VtvinqywuANaFu4bOMWki16nqf0e4oC0QIaDr/g==",
- "dev": true,
- "engines": {
- "node": ">=10"
- }
- },
- "node_modules/emoji-regex": {
- "version": "8.0.0",
- "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz",
- "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==",
- "dev": true
- },
- "node_modules/escalade": {
- "version": "3.1.1",
- "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz",
- "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==",
- "dev": true,
- "engines": {
- "node": ">=6"
- }
- },
- "node_modules/execa": {
- "version": "5.1.1",
- "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz",
- "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==",
- "dev": true,
- "dependencies": {
- "cross-spawn": "^7.0.3",
- "get-stream": "^6.0.0",
- "human-signals": "^2.1.0",
- "is-stream": "^2.0.0",
- "merge-stream": "^2.0.0",
- "npm-run-path": "^4.0.1",
- "onetime": "^5.1.2",
- "signal-exit": "^3.0.3",
- "strip-final-newline": "^2.0.0"
- },
- "engines": {
- "node": ">=10"
- },
- "funding": {
- "url": "https://github.com/sindresorhus/execa?sponsor=1"
- }
- },
- "node_modules/fast-deep-equal": {
- "version": "3.1.3",
- "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz",
- "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==",
- "dev": true
- },
- "node_modules/fill-range": {
- "version": "7.0.1",
- "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz",
- "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==",
- "dev": true,
- "dependencies": {
- "to-regex-range": "^5.0.1"
- },
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/fs-extra": {
- "version": "10.1.0",
- "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz",
- "integrity": "sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==",
- "dev": true,
- "dependencies": {
- "graceful-fs": "^4.2.0",
- "jsonfile": "^6.0.1",
- "universalify": "^2.0.0"
- },
- "engines": {
- "node": ">=12"
- }
- },
- "node_modules/fsevents": {
- "version": "2.3.2",
- "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz",
- "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==",
- "dev": true,
- "hasInstallScript": true,
- "optional": true,
- "os": [
- "darwin"
- ],
- "engines": {
- "node": "^8.16.0 || ^10.6.0 || >=11.0.0"
- }
- },
- "node_modules/function-bind": {
- "version": "1.1.1",
- "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz",
- "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==",
- "dev": true
- },
- "node_modules/get-caller-file": {
- "version": "2.0.5",
- "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz",
- "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==",
- "dev": true,
- "engines": {
- "node": "6.* || 8.* || >= 10.*"
- }
- },
- "node_modules/get-stream": {
- "version": "6.0.1",
- "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz",
- "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==",
- "dev": true,
- "engines": {
- "node": ">=10"
- },
- "funding": {
- "url": "https://github.com/sponsors/sindresorhus"
- }
- },
- "node_modules/glob-parent": {
- "version": "5.1.2",
- "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz",
- "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==",
- "dev": true,
- "dependencies": {
- "is-glob": "^4.0.1"
- },
- "engines": {
- "node": ">= 6"
- }
- },
- "node_modules/graceful-fs": {
- "version": "4.2.10",
- "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz",
- "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==",
- "dev": true
- },
- "node_modules/has": {
- "version": "1.0.3",
- "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz",
- "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==",
- "dev": true,
- "dependencies": {
- "function-bind": "^1.1.1"
- },
- "engines": {
- "node": ">= 0.4.0"
- }
- },
- "node_modules/has-flag": {
- "version": "4.0.0",
- "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
- "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
- "dev": true,
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/human-signals": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz",
- "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==",
- "dev": true,
- "engines": {
- "node": ">=10.17.0"
- }
- },
- "node_modules/husky": {
- "version": "8.0.3",
- "resolved": "https://registry.npmjs.org/husky/-/husky-8.0.3.tgz",
- "integrity": "sha512-+dQSyqPh4x1hlO1swXBiNb2HzTDN1I2IGLQx1GrBuiqFJfoMrnZWwVmatvSiO+Iz8fBUnf+lekwNo4c2LlXItg==",
- "dev": true,
- "bin": {
- "husky": "lib/bin.js"
- },
- "engines": {
- "node": ">=14"
- },
- "funding": {
- "url": "https://github.com/sponsors/typicode"
- }
- },
- "node_modules/is-binary-path": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz",
- "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==",
- "dev": true,
- "dependencies": {
- "binary-extensions": "^2.0.0"
- },
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/is-core-module": {
- "version": "2.9.0",
- "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.9.0.tgz",
- "integrity": "sha512-+5FPy5PnwmO3lvfMb0AsoPaBG+5KHUI0wYFXOtYPnVVVspTFUuMZNfNaNVRt3FZadstu2c8x23vykRW/NBoU6A==",
- "dev": true,
- "dependencies": {
- "has": "^1.0.3"
- },
- "funding": {
- "url": "https://github.com/sponsors/ljharb"
- }
- },
- "node_modules/is-extglob": {
- "version": "2.1.1",
- "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz",
- "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==",
- "dev": true,
- "engines": {
- "node": ">=0.10.0"
- }
- },
- "node_modules/is-fullwidth-code-point": {
- "version": "3.0.0",
- "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz",
- "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==",
- "dev": true,
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/is-glob": {
- "version": "4.0.3",
- "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz",
- "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==",
- "dev": true,
- "dependencies": {
- "is-extglob": "^2.1.1"
- },
- "engines": {
- "node": ">=0.10.0"
- }
- },
- "node_modules/is-number": {
- "version": "7.0.0",
- "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz",
- "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==",
- "dev": true,
- "engines": {
- "node": ">=0.12.0"
- }
- },
- "node_modules/is-stream": {
- "version": "2.0.1",
- "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz",
- "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==",
- "dev": true,
- "engines": {
- "node": ">=8"
- },
- "funding": {
- "url": "https://github.com/sponsors/sindresorhus"
- }
- },
- "node_modules/isexe": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz",
- "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==",
- "dev": true
- },
- "node_modules/json-schema-traverse": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz",
- "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==",
- "dev": true
- },
- "node_modules/jsonfile": {
- "version": "6.1.0",
- "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
- "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
- "dev": true,
- "dependencies": {
- "universalify": "^2.0.0"
- },
- "optionalDependencies": {
- "graceful-fs": "^4.1.6"
- }
- },
- "node_modules/kleur": {
- "version": "4.1.4",
- "resolved": "https://registry.npmjs.org/kleur/-/kleur-4.1.4.tgz",
- "integrity": "sha512-8QADVssbrFjivHWQU7KkMgptGTl6WAcSdlbBPY4uNF+mWr6DGcKrvY2w4FQJoXch7+fKMjj0dRrL75vk3k23OA==",
- "dev": true,
- "engines": {
- "node": ">=6"
- }
- },
- "node_modules/lookpath": {
- "version": "1.2.2",
- "resolved": "https://registry.npmjs.org/lookpath/-/lookpath-1.2.2.tgz",
- "integrity": "sha512-k2Gmn8iV6qdME3ztZC2spubmQISimFOPLuQKiPaLcVdRz0IpdxrNClVepMlyTJlhodm/zG/VfbkWERm3kUIh+Q==",
- "dev": true,
- "bin": {
- "lookpath": "bin/lookpath.js"
- },
- "engines": {
- "npm": ">=6.13.4"
- }
- },
- "node_modules/merge-stream": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz",
- "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==",
- "dev": true
- },
- "node_modules/mimic-fn": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz",
- "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==",
- "dev": true,
- "engines": {
- "node": ">=6"
- }
- },
- "node_modules/normalize-path": {
- "version": "3.0.0",
- "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz",
- "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==",
- "dev": true,
- "engines": {
- "node": ">=0.10.0"
- }
- },
- "node_modules/npm-run-path": {
- "version": "4.0.1",
- "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz",
- "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==",
- "dev": true,
- "dependencies": {
- "path-key": "^3.0.0"
- },
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/onetime": {
- "version": "5.1.2",
- "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz",
- "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==",
- "dev": true,
- "dependencies": {
- "mimic-fn": "^2.1.0"
- },
- "engines": {
- "node": ">=6"
- },
- "funding": {
- "url": "https://github.com/sponsors/sindresorhus"
- }
- },
- "node_modules/path-key": {
- "version": "3.1.1",
- "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz",
- "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==",
- "dev": true,
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/path-parse": {
- "version": "1.0.7",
- "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz",
- "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==",
- "dev": true
- },
- "node_modules/picomatch": {
- "version": "2.3.1",
- "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz",
- "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==",
- "dev": true,
- "engines": {
- "node": ">=8.6"
- },
- "funding": {
- "url": "https://github.com/sponsors/jonschlinkert"
- }
- },
- "node_modules/prompts": {
- "version": "2.4.2",
- "resolved": "https://registry.npmjs.org/prompts/-/prompts-2.4.2.tgz",
- "integrity": "sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q==",
- "dev": true,
- "dependencies": {
- "kleur": "^3.0.3",
- "sisteransi": "^1.0.5"
- },
- "engines": {
- "node": ">= 6"
- }
- },
- "node_modules/prompts/node_modules/kleur": {
- "version": "3.0.3",
- "resolved": "https://registry.npmjs.org/kleur/-/kleur-3.0.3.tgz",
- "integrity": "sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==",
- "dev": true,
- "engines": {
- "node": ">=6"
- }
- },
- "node_modules/punycode": {
- "version": "2.1.1",
- "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz",
- "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==",
- "dev": true,
- "engines": {
- "node": ">=6"
- }
- },
- "node_modules/rbxts-transform-debug": {
- "version": "1.0.0-ts4.5",
- "resolved": "https://registry.npmjs.org/rbxts-transform-debug/-/rbxts-transform-debug-1.0.0-ts4.5.tgz",
- "integrity": "sha512-zaHEoEHcq6/uhVaFFfj9WgYWlVqaSpNj0ac9Es0fDQzDBHMt6VGoyZDGw0yWm4MTZoM+K0676ByszZ1RghHlaQ==",
- "dev": true,
- "dependencies": {
- "chalk": "^4.1.0",
- "colors": "^1.4.0",
- "dotenv": "^8.2.0",
- "execa": "^5.1.1",
- "typescript": "~4.5.4"
- }
- },
- "node_modules/rbxts-transform-debug/node_modules/typescript": {
- "version": "4.5.5",
- "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.5.5.tgz",
- "integrity": "sha512-TCTIul70LyWe6IJWT8QSYeA54WQe8EjQFU4wY52Fasj5UKx88LNYKCgBEHcOMOrFF1rKGbD8v/xcNWVUq9SymA==",
- "dev": true,
- "bin": {
- "tsc": "bin/tsc",
- "tsserver": "bin/tsserver"
- },
- "engines": {
- "node": ">=4.2.0"
- }
- },
- "node_modules/rbxts-transform-env": {
- "version": "1.0.0-ts4.5",
- "resolved": "https://registry.npmjs.org/rbxts-transform-env/-/rbxts-transform-env-1.0.0-ts4.5.tgz",
- "integrity": "sha512-VokMFb364Kq1DP5x/kXdhpPk1CH3cpCufnmDwp+QR1QjvrAuC+9GVO8CzfRniuxu9JZSWQ6DOYFfatiAJ2l1Vw==",
- "dev": true,
- "dependencies": {
- "chalk": "^4.1.1",
- "colors": "^1.4.0",
- "dotenv": "^8.2.0",
- "typescript": "~4.5.4"
- }
- },
- "node_modules/rbxts-transform-env/node_modules/typescript": {
- "version": "4.5.5",
- "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.5.5.tgz",
- "integrity": "sha512-TCTIul70LyWe6IJWT8QSYeA54WQe8EjQFU4wY52Fasj5UKx88LNYKCgBEHcOMOrFF1rKGbD8v/xcNWVUq9SymA==",
- "dev": true,
- "bin": {
- "tsc": "bin/tsc",
- "tsserver": "bin/tsserver"
- },
- "engines": {
- "node": ">=4.2.0"
- }
- },
- "node_modules/readdirp": {
- "version": "3.6.0",
- "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz",
- "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==",
- "dev": true,
- "dependencies": {
- "picomatch": "^2.2.1"
- },
- "engines": {
- "node": ">=8.10.0"
- }
- },
- "node_modules/require-directory": {
- "version": "2.1.1",
- "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz",
- "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=",
- "dev": true,
- "engines": {
- "node": ">=0.10.0"
- }
- },
- "node_modules/require-from-string": {
- "version": "2.0.2",
- "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz",
- "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==",
- "dev": true,
- "engines": {
- "node": ">=0.10.0"
- }
- },
- "node_modules/resolve": {
- "version": "1.22.0",
- "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.0.tgz",
- "integrity": "sha512-Hhtrw0nLeSrFQ7phPp4OOcVjLPIeMnRlr5mcnVuMe7M/7eBn98A3hmFRLoFo3DLZkivSYwhRUJTyPyWAk56WLw==",
- "dev": true,
- "dependencies": {
- "is-core-module": "^2.8.1",
- "path-parse": "^1.0.7",
- "supports-preserve-symlinks-flag": "^1.0.0"
- },
- "bin": {
- "resolve": "bin/resolve"
- },
- "funding": {
- "url": "https://github.com/sponsors/ljharb"
- }
- },
- "node_modules/roblox-ts": {
- "version": "1.3.3",
- "resolved": "https://registry.npmjs.org/roblox-ts/-/roblox-ts-1.3.3.tgz",
- "integrity": "sha512-lInd8WSnTQ2h81maDKG/aH4GVx+iKRWdE/CcfjNZR61ir9r6MdxPlRhoYoh8Blb1ceZMCPLsAMXsK//sQu8C2g==",
- "dev": true,
- "dependencies": {
- "@roblox-ts/luau-ast": "^1.0.1",
- "@roblox-ts/rojo-resolver": "^1.0.2",
- "ajv": "^8.6.3",
- "chokidar": "^3.5.2",
- "fs-extra": "^10.0.0",
- "kleur": "^4.1.4",
- "lookpath": "^1.2.2",
- "prompts": "^2.4.1",
- "resolve": "^1.20.0",
- "typescript": "=4.6.2",
- "yargs": "^17.2.0"
- },
- "bin": {
- "rbxtsc": "out/CLI/cli.js"
- }
- },
- "node_modules/roblox-ts/node_modules/typescript": {
- "version": "4.6.2",
- "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.6.2.tgz",
- "integrity": "sha512-HM/hFigTBHZhLXshn9sN37H085+hQGeJHJ/X7LpBWLID/fbc2acUMfU+lGD98X81sKP+pFa9f0DZmCwB9GnbAg==",
- "dev": true,
- "bin": {
- "tsc": "bin/tsc",
- "tsserver": "bin/tsserver"
- },
- "engines": {
- "node": ">=4.2.0"
- }
- },
- "node_modules/shebang-command": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz",
- "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==",
- "dev": true,
- "dependencies": {
- "shebang-regex": "^3.0.0"
- },
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/shebang-regex": {
- "version": "3.0.0",
- "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz",
- "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==",
- "dev": true,
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/signal-exit": {
- "version": "3.0.7",
- "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz",
- "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==",
- "dev": true
- },
- "node_modules/sisteransi": {
- "version": "1.0.5",
- "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz",
- "integrity": "sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==",
- "dev": true
- },
- "node_modules/string-width": {
- "version": "4.2.3",
- "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz",
- "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==",
- "dev": true,
- "dependencies": {
- "emoji-regex": "^8.0.0",
- "is-fullwidth-code-point": "^3.0.0",
- "strip-ansi": "^6.0.1"
- },
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/strip-ansi": {
- "version": "6.0.1",
- "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz",
- "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==",
- "dev": true,
- "dependencies": {
- "ansi-regex": "^5.0.1"
- },
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/strip-final-newline": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz",
- "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==",
- "dev": true,
- "engines": {
- "node": ">=6"
- }
- },
- "node_modules/supports-color": {
- "version": "7.2.0",
- "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
- "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
- "dev": true,
- "dependencies": {
- "has-flag": "^4.0.0"
- },
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/supports-preserve-symlinks-flag": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz",
- "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==",
- "dev": true,
- "engines": {
- "node": ">= 0.4"
- },
- "funding": {
- "url": "https://github.com/sponsors/ljharb"
- }
- },
- "node_modules/to-regex-range": {
- "version": "5.0.1",
- "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz",
- "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==",
- "dev": true,
- "dependencies": {
- "is-number": "^7.0.0"
- },
- "engines": {
- "node": ">=8.0"
- }
- },
- "node_modules/typescript": {
- "version": "4.7.3",
- "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.7.3.tgz",
- "integrity": "sha512-WOkT3XYvrpXx4vMMqlD+8R8R37fZkjyLGlxavMc4iB8lrl8L0DeTcHbYgw/v0N/z9wAFsgBhcsF0ruoySS22mA==",
- "dev": true,
- "bin": {
- "tsc": "bin/tsc",
- "tsserver": "bin/tsserver"
- },
- "engines": {
- "node": ">=4.2.0"
- }
- },
- "node_modules/universalify": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.0.tgz",
- "integrity": "sha512-hAZsKq7Yy11Zu1DE0OzWjw7nnLZmJZYTDZZyEFHZdUhV8FkH5MCfoU1XMaxXovpyW5nq5scPqq0ZDP9Zyl04oQ==",
- "dev": true,
- "engines": {
- "node": ">= 10.0.0"
- }
- },
- "node_modules/uri-js": {
- "version": "4.4.1",
- "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz",
- "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==",
- "dev": true,
- "dependencies": {
- "punycode": "^2.1.0"
- }
- },
- "node_modules/which": {
- "version": "2.0.2",
- "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz",
- "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==",
- "dev": true,
- "dependencies": {
- "isexe": "^2.0.0"
- },
- "bin": {
- "node-which": "bin/node-which"
- },
- "engines": {
- "node": ">= 8"
- }
- },
- "node_modules/wrap-ansi": {
- "version": "7.0.0",
- "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz",
- "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==",
- "dev": true,
- "dependencies": {
- "ansi-styles": "^4.0.0",
- "string-width": "^4.1.0",
- "strip-ansi": "^6.0.0"
- },
- "engines": {
- "node": ">=10"
- },
- "funding": {
- "url": "https://github.com/chalk/wrap-ansi?sponsor=1"
- }
- },
- "node_modules/y18n": {
- "version": "5.0.8",
- "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz",
- "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==",
- "dev": true,
- "engines": {
- "node": ">=10"
- }
- },
- "node_modules/yargs": {
- "version": "17.5.1",
- "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.5.1.tgz",
- "integrity": "sha512-t6YAJcxDkNX7NFYiVtKvWUz8l+PaKTLiL63mJYWR2GnHq2gjEWISzsLp9wg3aY36dY1j+gfIEL3pIF+XlJJfbA==",
- "dev": true,
- "dependencies": {
- "cliui": "^7.0.2",
- "escalade": "^3.1.1",
- "get-caller-file": "^2.0.5",
- "require-directory": "^2.1.1",
- "string-width": "^4.2.3",
- "y18n": "^5.0.5",
- "yargs-parser": "^21.0.0"
- },
- "engines": {
- "node": ">=12"
- }
- },
- "node_modules/yargs-parser": {
- "version": "21.0.1",
- "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.0.1.tgz",
- "integrity": "sha512-9BK1jFpLzJROCI5TzwZL/TU4gqjK5xiHV/RfWLOahrjAko/e4DJkRDZQXfvqAsiZzzYhgAzbgz6lg48jcm4GLg==",
- "dev": true,
- "engines": {
- "node": ">=12"
- }
- }
- },
- "dependencies": {
- "@rbxts/compiler-types": {
- "version": "1.2.3-types.1",
- "resolved": "https://registry.npmjs.org/@rbxts/compiler-types/-/compiler-types-1.2.3-types.1.tgz",
- "integrity": "sha512-SXXIBazyJ7N6d2xcy471/kqZZpCv7EDOWrRJ45jcv3g00VQaZwYl4Elr10woqRloIblQanwJ7yUqGXAsWv7iuQ==",
- "dev": true
- },
- "@rbxts/types": {
- "version": "1.0.591",
- "resolved": "https://registry.npmjs.org/@rbxts/types/-/types-1.0.591.tgz",
- "integrity": "sha512-72lPUo6ecDxwdL8MhAgyFZiNQ6+/8hSHZDW8IcP6IRdHKn4zq9ABwsQjeIsWuKSI/EgG6k9LrTAdcG9FDaxUYw==",
- "dev": true
- },
- "@roblox-ts/luau-ast": {
- "version": "1.0.1",
- "resolved": "https://registry.npmjs.org/@roblox-ts/luau-ast/-/luau-ast-1.0.1.tgz",
- "integrity": "sha512-FTKP24O0EbGupOmfJ6UHpag0K597bCpN4veDP9N91hSsrhIIHV59xLYw/e97g6hmwqYBfxOCuAvuLvsR4C9aMw==",
- "dev": true
- },
- "@roblox-ts/rojo-resolver": {
- "version": "1.0.2",
- "resolved": "https://registry.npmjs.org/@roblox-ts/rojo-resolver/-/rojo-resolver-1.0.2.tgz",
- "integrity": "sha512-491pyfdxA7cmhDlY23rQi1rEuLCl0mPeAOUQbd6XdiaZ461MMtj38lvn1f8SXd6ZoZ/S4cO0XQUcKEBDGMdM2Q==",
- "dev": true,
- "requires": {
- "ajv": "^8.6.3",
- "fs-extra": "^10.0.0"
- }
- },
- "ajv": {
- "version": "8.11.0",
- "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.11.0.tgz",
- "integrity": "sha512-wGgprdCvMalC0BztXvitD2hC04YffAvtsUn93JbGXYLAtCUO4xd17mCCZQxUOItiBwZvJScWo8NIvQMQ71rdpg==",
- "dev": true,
- "requires": {
- "fast-deep-equal": "^3.1.1",
- "json-schema-traverse": "^1.0.0",
- "require-from-string": "^2.0.2",
- "uri-js": "^4.2.2"
- }
- },
- "ansi-regex": {
- "version": "5.0.1",
- "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz",
- "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==",
- "dev": true
- },
- "ansi-styles": {
- "version": "4.3.0",
- "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
- "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
- "dev": true,
- "requires": {
- "color-convert": "^2.0.1"
- }
- },
- "anymatch": {
- "version": "3.1.2",
- "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.2.tgz",
- "integrity": "sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg==",
- "dev": true,
- "requires": {
- "normalize-path": "^3.0.0",
- "picomatch": "^2.0.4"
- }
- },
- "binary-extensions": {
- "version": "2.2.0",
- "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz",
- "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==",
- "dev": true
- },
- "braces": {
- "version": "3.0.2",
- "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz",
- "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==",
- "dev": true,
- "requires": {
- "fill-range": "^7.0.1"
- }
- },
- "chalk": {
- "version": "4.1.2",
- "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
- "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
- "dev": true,
- "requires": {
- "ansi-styles": "^4.1.0",
- "supports-color": "^7.1.0"
- }
- },
- "chokidar": {
- "version": "3.5.3",
- "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz",
- "integrity": "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==",
- "dev": true,
- "requires": {
- "anymatch": "~3.1.2",
- "braces": "~3.0.2",
- "fsevents": "~2.3.2",
- "glob-parent": "~5.1.2",
- "is-binary-path": "~2.1.0",
- "is-glob": "~4.0.1",
- "normalize-path": "~3.0.0",
- "readdirp": "~3.6.0"
- }
- },
- "cliui": {
- "version": "7.0.4",
- "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz",
- "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==",
- "dev": true,
- "requires": {
- "string-width": "^4.2.0",
- "strip-ansi": "^6.0.0",
- "wrap-ansi": "^7.0.0"
- }
- },
- "color-convert": {
- "version": "2.0.1",
- "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
- "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
- "dev": true,
- "requires": {
- "color-name": "~1.1.4"
- }
- },
- "color-name": {
- "version": "1.1.4",
- "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
- "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
- "dev": true
- },
- "colors": {
- "version": "1.4.0",
- "resolved": "https://registry.npmjs.org/colors/-/colors-1.4.0.tgz",
- "integrity": "sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA==",
- "dev": true
- },
- "cross-spawn": {
- "version": "7.0.3",
- "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz",
- "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==",
- "dev": true,
- "requires": {
- "path-key": "^3.1.0",
- "shebang-command": "^2.0.0",
- "which": "^2.0.1"
- }
- },
- "dotenv": {
- "version": "8.6.0",
- "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-8.6.0.tgz",
- "integrity": "sha512-IrPdXQsk2BbzvCBGBOTmmSH5SodmqZNt4ERAZDmW4CT+tL8VtvinqywuANaFu4bOMWki16nqf0e4oC0QIaDr/g==",
- "dev": true
- },
- "emoji-regex": {
- "version": "8.0.0",
- "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz",
- "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==",
- "dev": true
- },
- "escalade": {
- "version": "3.1.1",
- "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz",
- "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==",
- "dev": true
- },
- "execa": {
- "version": "5.1.1",
- "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz",
- "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==",
- "dev": true,
- "requires": {
- "cross-spawn": "^7.0.3",
- "get-stream": "^6.0.0",
- "human-signals": "^2.1.0",
- "is-stream": "^2.0.0",
- "merge-stream": "^2.0.0",
- "npm-run-path": "^4.0.1",
- "onetime": "^5.1.2",
- "signal-exit": "^3.0.3",
- "strip-final-newline": "^2.0.0"
- }
- },
- "fast-deep-equal": {
- "version": "3.1.3",
- "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz",
- "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==",
- "dev": true
- },
- "fill-range": {
- "version": "7.0.1",
- "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz",
- "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==",
- "dev": true,
- "requires": {
- "to-regex-range": "^5.0.1"
- }
- },
- "fs-extra": {
- "version": "10.1.0",
- "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz",
- "integrity": "sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==",
- "dev": true,
- "requires": {
- "graceful-fs": "^4.2.0",
- "jsonfile": "^6.0.1",
- "universalify": "^2.0.0"
- }
- },
- "fsevents": {
- "version": "2.3.2",
- "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz",
- "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==",
- "dev": true,
- "optional": true
- },
- "function-bind": {
- "version": "1.1.1",
- "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz",
- "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==",
- "dev": true
- },
- "get-caller-file": {
- "version": "2.0.5",
- "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz",
- "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==",
- "dev": true
- },
- "get-stream": {
- "version": "6.0.1",
- "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz",
- "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==",
- "dev": true
- },
- "glob-parent": {
- "version": "5.1.2",
- "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz",
- "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==",
- "dev": true,
- "requires": {
- "is-glob": "^4.0.1"
- }
- },
- "graceful-fs": {
- "version": "4.2.10",
- "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz",
- "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==",
- "dev": true
- },
- "has": {
- "version": "1.0.3",
- "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz",
- "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==",
- "dev": true,
- "requires": {
- "function-bind": "^1.1.1"
- }
- },
- "has-flag": {
- "version": "4.0.0",
- "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
- "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
- "dev": true
- },
- "human-signals": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz",
- "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==",
- "dev": true
- },
- "husky": {
- "version": "8.0.3",
- "resolved": "https://registry.npmjs.org/husky/-/husky-8.0.3.tgz",
- "integrity": "sha512-+dQSyqPh4x1hlO1swXBiNb2HzTDN1I2IGLQx1GrBuiqFJfoMrnZWwVmatvSiO+Iz8fBUnf+lekwNo4c2LlXItg==",
- "dev": true
- },
- "is-binary-path": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz",
- "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==",
- "dev": true,
- "requires": {
- "binary-extensions": "^2.0.0"
- }
- },
- "is-core-module": {
- "version": "2.9.0",
- "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.9.0.tgz",
- "integrity": "sha512-+5FPy5PnwmO3lvfMb0AsoPaBG+5KHUI0wYFXOtYPnVVVspTFUuMZNfNaNVRt3FZadstu2c8x23vykRW/NBoU6A==",
- "dev": true,
- "requires": {
- "has": "^1.0.3"
- }
- },
- "is-extglob": {
- "version": "2.1.1",
- "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz",
- "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==",
- "dev": true
- },
- "is-fullwidth-code-point": {
- "version": "3.0.0",
- "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz",
- "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==",
- "dev": true
- },
- "is-glob": {
- "version": "4.0.3",
- "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz",
- "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==",
- "dev": true,
- "requires": {
- "is-extglob": "^2.1.1"
- }
- },
- "is-number": {
- "version": "7.0.0",
- "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz",
- "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==",
- "dev": true
- },
- "is-stream": {
- "version": "2.0.1",
- "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz",
- "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==",
- "dev": true
- },
- "isexe": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz",
- "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==",
- "dev": true
- },
- "json-schema-traverse": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz",
- "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==",
- "dev": true
- },
- "jsonfile": {
- "version": "6.1.0",
- "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
- "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
- "dev": true,
- "requires": {
- "graceful-fs": "^4.1.6",
- "universalify": "^2.0.0"
- }
- },
- "kleur": {
- "version": "4.1.4",
- "resolved": "https://registry.npmjs.org/kleur/-/kleur-4.1.4.tgz",
- "integrity": "sha512-8QADVssbrFjivHWQU7KkMgptGTl6WAcSdlbBPY4uNF+mWr6DGcKrvY2w4FQJoXch7+fKMjj0dRrL75vk3k23OA==",
- "dev": true
- },
- "lookpath": {
- "version": "1.2.2",
- "resolved": "https://registry.npmjs.org/lookpath/-/lookpath-1.2.2.tgz",
- "integrity": "sha512-k2Gmn8iV6qdME3ztZC2spubmQISimFOPLuQKiPaLcVdRz0IpdxrNClVepMlyTJlhodm/zG/VfbkWERm3kUIh+Q==",
- "dev": true
- },
- "merge-stream": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz",
- "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==",
- "dev": true
- },
- "mimic-fn": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz",
- "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==",
- "dev": true
- },
- "normalize-path": {
- "version": "3.0.0",
- "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz",
- "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==",
- "dev": true
- },
- "npm-run-path": {
- "version": "4.0.1",
- "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz",
- "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==",
- "dev": true,
- "requires": {
- "path-key": "^3.0.0"
- }
- },
- "onetime": {
- "version": "5.1.2",
- "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz",
- "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==",
- "dev": true,
- "requires": {
- "mimic-fn": "^2.1.0"
- }
- },
- "path-key": {
- "version": "3.1.1",
- "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz",
- "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==",
- "dev": true
- },
- "path-parse": {
- "version": "1.0.7",
- "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz",
- "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==",
- "dev": true
- },
- "picomatch": {
- "version": "2.3.1",
- "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz",
- "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==",
- "dev": true
- },
- "prompts": {
- "version": "2.4.2",
- "resolved": "https://registry.npmjs.org/prompts/-/prompts-2.4.2.tgz",
- "integrity": "sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q==",
- "dev": true,
- "requires": {
- "kleur": "^3.0.3",
- "sisteransi": "^1.0.5"
- },
- "dependencies": {
- "kleur": {
- "version": "3.0.3",
- "resolved": "https://registry.npmjs.org/kleur/-/kleur-3.0.3.tgz",
- "integrity": "sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==",
- "dev": true
- }
- }
- },
- "punycode": {
- "version": "2.1.1",
- "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz",
- "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==",
- "dev": true
- },
- "rbxts-transform-debug": {
- "version": "1.0.0-ts4.5",
- "resolved": "https://registry.npmjs.org/rbxts-transform-debug/-/rbxts-transform-debug-1.0.0-ts4.5.tgz",
- "integrity": "sha512-zaHEoEHcq6/uhVaFFfj9WgYWlVqaSpNj0ac9Es0fDQzDBHMt6VGoyZDGw0yWm4MTZoM+K0676ByszZ1RghHlaQ==",
- "dev": true,
- "requires": {
- "chalk": "^4.1.0",
- "colors": "^1.4.0",
- "dotenv": "^8.2.0",
- "execa": "^5.1.1",
- "typescript": "~4.5.4"
- },
- "dependencies": {
- "typescript": {
- "version": "4.5.5",
- "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.5.5.tgz",
- "integrity": "sha512-TCTIul70LyWe6IJWT8QSYeA54WQe8EjQFU4wY52Fasj5UKx88LNYKCgBEHcOMOrFF1rKGbD8v/xcNWVUq9SymA==",
- "dev": true
- }
- }
- },
- "rbxts-transform-env": {
- "version": "1.0.0-ts4.5",
- "resolved": "https://registry.npmjs.org/rbxts-transform-env/-/rbxts-transform-env-1.0.0-ts4.5.tgz",
- "integrity": "sha512-VokMFb364Kq1DP5x/kXdhpPk1CH3cpCufnmDwp+QR1QjvrAuC+9GVO8CzfRniuxu9JZSWQ6DOYFfatiAJ2l1Vw==",
- "dev": true,
- "requires": {
- "chalk": "^4.1.1",
- "colors": "^1.4.0",
- "dotenv": "^8.2.0",
- "typescript": "~4.5.4"
- },
- "dependencies": {
- "typescript": {
- "version": "4.5.5",
- "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.5.5.tgz",
- "integrity": "sha512-TCTIul70LyWe6IJWT8QSYeA54WQe8EjQFU4wY52Fasj5UKx88LNYKCgBEHcOMOrFF1rKGbD8v/xcNWVUq9SymA==",
- "dev": true
- }
- }
- },
- "readdirp": {
- "version": "3.6.0",
- "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz",
- "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==",
- "dev": true,
- "requires": {
- "picomatch": "^2.2.1"
- }
- },
- "require-directory": {
- "version": "2.1.1",
- "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz",
- "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=",
- "dev": true
- },
- "require-from-string": {
- "version": "2.0.2",
- "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz",
- "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==",
- "dev": true
- },
- "resolve": {
- "version": "1.22.0",
- "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.0.tgz",
- "integrity": "sha512-Hhtrw0nLeSrFQ7phPp4OOcVjLPIeMnRlr5mcnVuMe7M/7eBn98A3hmFRLoFo3DLZkivSYwhRUJTyPyWAk56WLw==",
- "dev": true,
- "requires": {
- "is-core-module": "^2.8.1",
- "path-parse": "^1.0.7",
- "supports-preserve-symlinks-flag": "^1.0.0"
- }
- },
- "roblox-ts": {
- "version": "1.3.3",
- "resolved": "https://registry.npmjs.org/roblox-ts/-/roblox-ts-1.3.3.tgz",
- "integrity": "sha512-lInd8WSnTQ2h81maDKG/aH4GVx+iKRWdE/CcfjNZR61ir9r6MdxPlRhoYoh8Blb1ceZMCPLsAMXsK//sQu8C2g==",
- "dev": true,
- "requires": {
- "@roblox-ts/luau-ast": "^1.0.1",
- "@roblox-ts/rojo-resolver": "^1.0.2",
- "ajv": "^8.6.3",
- "chokidar": "^3.5.2",
- "fs-extra": "^10.0.0",
- "kleur": "^4.1.4",
- "lookpath": "^1.2.2",
- "prompts": "^2.4.1",
- "resolve": "^1.20.0",
- "typescript": "=4.6.2",
- "yargs": "^17.2.0"
- },
- "dependencies": {
- "typescript": {
- "version": "4.6.2",
- "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.6.2.tgz",
- "integrity": "sha512-HM/hFigTBHZhLXshn9sN37H085+hQGeJHJ/X7LpBWLID/fbc2acUMfU+lGD98X81sKP+pFa9f0DZmCwB9GnbAg==",
- "dev": true
- }
- }
- },
- "shebang-command": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz",
- "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==",
- "dev": true,
- "requires": {
- "shebang-regex": "^3.0.0"
- }
- },
- "shebang-regex": {
- "version": "3.0.0",
- "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz",
- "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==",
- "dev": true
- },
- "signal-exit": {
- "version": "3.0.7",
- "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz",
- "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==",
- "dev": true
- },
- "sisteransi": {
- "version": "1.0.5",
- "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz",
- "integrity": "sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==",
- "dev": true
- },
- "string-width": {
- "version": "4.2.3",
- "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz",
- "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==",
- "dev": true,
- "requires": {
- "emoji-regex": "^8.0.0",
- "is-fullwidth-code-point": "^3.0.0",
- "strip-ansi": "^6.0.1"
- }
- },
- "strip-ansi": {
- "version": "6.0.1",
- "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz",
- "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==",
- "dev": true,
- "requires": {
- "ansi-regex": "^5.0.1"
- }
- },
- "strip-final-newline": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz",
- "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==",
- "dev": true
- },
- "supports-color": {
- "version": "7.2.0",
- "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
- "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
- "dev": true,
- "requires": {
- "has-flag": "^4.0.0"
- }
- },
- "supports-preserve-symlinks-flag": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz",
- "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==",
- "dev": true
- },
- "to-regex-range": {
- "version": "5.0.1",
- "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz",
- "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==",
- "dev": true,
- "requires": {
- "is-number": "^7.0.0"
- }
- },
- "typescript": {
- "version": "4.7.3",
- "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.7.3.tgz",
- "integrity": "sha512-WOkT3XYvrpXx4vMMqlD+8R8R37fZkjyLGlxavMc4iB8lrl8L0DeTcHbYgw/v0N/z9wAFsgBhcsF0ruoySS22mA==",
- "dev": true
- },
- "universalify": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.0.tgz",
- "integrity": "sha512-hAZsKq7Yy11Zu1DE0OzWjw7nnLZmJZYTDZZyEFHZdUhV8FkH5MCfoU1XMaxXovpyW5nq5scPqq0ZDP9Zyl04oQ==",
- "dev": true
- },
- "uri-js": {
- "version": "4.4.1",
- "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz",
- "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==",
- "dev": true,
- "requires": {
- "punycode": "^2.1.0"
- }
- },
- "which": {
- "version": "2.0.2",
- "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz",
- "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==",
- "dev": true,
- "requires": {
- "isexe": "^2.0.0"
- }
- },
- "wrap-ansi": {
- "version": "7.0.0",
- "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz",
- "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==",
- "dev": true,
- "requires": {
- "ansi-styles": "^4.0.0",
- "string-width": "^4.1.0",
- "strip-ansi": "^6.0.0"
- }
- },
- "y18n": {
- "version": "5.0.8",
- "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz",
- "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==",
- "dev": true
- },
- "yargs": {
- "version": "17.5.1",
- "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.5.1.tgz",
- "integrity": "sha512-t6YAJcxDkNX7NFYiVtKvWUz8l+PaKTLiL63mJYWR2GnHq2gjEWISzsLp9wg3aY36dY1j+gfIEL3pIF+XlJJfbA==",
- "dev": true,
- "requires": {
- "cliui": "^7.0.2",
- "escalade": "^3.1.1",
- "get-caller-file": "^2.0.5",
- "require-directory": "^2.1.1",
- "string-width": "^4.2.3",
- "y18n": "^5.0.5",
- "yargs-parser": "^21.0.0"
- }
- },
- "yargs-parser": {
- "version": "21.0.1",
- "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.0.1.tgz",
- "integrity": "sha512-9BK1jFpLzJROCI5TzwZL/TU4gqjK5xiHV/RfWLOahrjAko/e4DJkRDZQXfvqAsiZzzYhgAzbgz6lg48jcm4GLg==",
- "dev": true
- }
- }
-}
diff --git a/selene.toml b/selene.toml
index 49fb47e..c4ddb46 100644
--- a/selene.toml
+++ b/selene.toml
@@ -1 +1 @@
-std = "roblox+testez"
+std = "roblox"
diff --git a/testez.toml b/testez.toml
deleted file mode 100644
index adc2434..0000000
--- a/testez.toml
+++ /dev/null
@@ -1,67 +0,0 @@
-# TestEZ
-[[afterAll.args]]
-type = "function"
-
-[[afterEach.args]]
-type = "function"
-
-[[beforeAll.args]]
-type = "function"
-
-[[beforeEach.args]]
-type = "function"
-
-[[describe.args]]
-type = "string"
-
-[[describe.args]]
-type = "function"
-
-[[describeFOCUS.args]]
-type = "string"
-
-[[describeFOCUS.args]]
-type = "function"
-
-[[describeSKIP.args]]
-type = "string"
-
-[[describeSKIP.args]]
-type = "function"
-
-[[expect.args]]
-type = "any"
-
-[[FIXME.args]]
-type = "string"
-required = false
-
-[FOCUS]
-args = []
-
-[[it.args]]
-type = "string"
-
-[[it.args]]
-type = "function"
-
-[[itFIXME.args]]
-type = "string"
-
-[[itFIXME.args]]
-type = "function"
-
-[[itFOCUS.args]]
-type = "string"
-
-[[itFOCUS.args]]
-type = "function"
-
-[[itSKIP.args]]
-type = "string"
-
-[[itSKIP.args]]
-type = "function"
-
-[SKIP]
-args = []
From 8fb132354747bf63cae7c30956559ecc5378f3dc Mon Sep 17 00:00:00 2001
From: Cam <21029087+cxmeel@users.noreply.github.com>
Date: Mon, 11 Mar 2024 17:09:29 +0000
Subject: [PATCH 02/43] Remove testez tests
---
.gitattributes | 3 +
.github/FUNDING.yml | 4 +-
.github/workflows/publish.yml | 58 ------
.gitignore | 18 +-
.luaurc | 8 +
.stylua.toml | 7 -
CHANGELOG.md | 61 -------
README.md | 33 ++--
aftman.toml | 13 +-
default.project.json | 5 +-
docs/Installation.md | 10 +-
moonwave.toml | 4 +-
package.json | 9 +-
sourcemap.json | 2 +-
src/Array/at.spec.lua | 25 ---
src/Array/concat.spec.lua | 53 ------
src/Array/concatDeep.spec.lua | 53 ------
src/Array/copy.spec.lua | 29 ---
src/Array/copyDeep.spec.lua | 43 -----
src/Array/count.spec.lua | 29 ---
src/Array/create.spec.lua | 14 --
src/Array/difference.spec.lua | 40 -----
src/Array/differenceSymmetric.spec.lua | 47 -----
src/Array/equals.spec.lua | 29 ---
src/Array/equalsDeep.spec.lua | 24 ---
src/Array/every.spec.lua | 19 --
src/Array/filter.spec.lua | 36 ----
src/Array/find.spec.lua | 33 ----
src/Array/findLast.spec.lua | 33 ----
src/Array/findWhere.spec.lua | 49 -----
src/Array/findWhereLast.spec.lua | 38 ----
src/Array/first.spec.lua | 11 --
src/Array/flatten.spec.lua | 48 -----
src/Array/freeze.spec.lua | 48 -----
src/Array/freezeDeep.spec.lua | 48 -----
src/Array/includes.spec.lua | 11 --
src/Array/insert.spec.lua | 57 ------
src/Array/is.spec.lua | 11 --
src/Array/last.spec.lua | 11 --
src/Array/map.spec.lua | 31 ----
src/Array/pop.spec.lua | 32 ----
src/Array/push.spec.lua | 29 ---
src/Array/reduce.spec.lua | 36 ----
src/Array/reduceRight.spec.lua | 39 ----
src/Array/removeIndex.spec.lua | 31 ----
src/Array/removeIndices.spec.lua | 33 ----
src/Array/removeValue.spec.lua | 23 ---
src/Array/removeValues.spec.lua | 22 ---
src/Array/reverse.spec.lua | 23 ---
src/Array/set.spec.lua | 21 ---
src/Array/shift.spec.lua | 32 ----
src/Array/shuffle.spec.lua | 13 --
src/Array/slice.spec.lua | 47 -----
src/Array/some.spec.lua | 23 ---
src/Array/sort.spec.lua | 44 -----
src/Array/splice.spec.lua | 27 ---
src/Array/toSet.spec.lua | 38 ----
src/Array/unshift.spec.lua | 41 -----
src/Array/update.spec.lua | 48 -----
src/Array/zip.spec.lua | 46 -----
src/Array/zipAll.spec.lua | 69 -------
src/Dictionary/copy.spec.lua | 25 ---
src/Dictionary/copyDeep.spec.lua | 52 ------
src/Dictionary/count.spec.lua | 29 ---
src/Dictionary/entries.spec.lua | 22 ---
src/Dictionary/equals.spec.lua | 29 ---
src/Dictionary/equalsDeep.spec.lua | 26 ---
src/Dictionary/every.spec.lua | 19 --
src/Dictionary/filter.spec.lua | 34 ----
src/Dictionary/flatten.spec.lua | 64 -------
src/Dictionary/flip.spec.lua | 14 --
src/Dictionary/freeze.spec.lua | 42 -----
src/Dictionary/freezeDeep.spec.lua | 43 -----
src/Dictionary/fromArrays.spec.lua | 15 --
src/Dictionary/fromEntries.spec.lua | 14 --
src/Dictionary/has.spec.lua | 19 --
src/Dictionary/includes.spec.lua | 19 --
src/Dictionary/keys.spec.lua | 15 --
src/Dictionary/map.spec.lua | 27 ---
src/Dictionary/merge.spec.lua | 61 -------
src/Dictionary/mergeDeep.spec.lua | 61 -------
src/Dictionary/removeKey.spec.lua | 25 ---
src/Dictionary/removeKeys.spec.lua | 29 ---
src/Dictionary/removeValue.spec.lua | 25 ---
src/Dictionary/removeValues.spec.lua | 29 ---
src/Dictionary/set.spec.lua | 25 ---
src/Dictionary/some.spec.lua | 23 ---
src/Dictionary/update.spec.lua | 57 ------
src/Dictionary/values.spec.lua | 15 --
src/Dictionary/withKeys.spec.lua | 29 ---
src/Set/add.spec.lua | 25 ---
src/Set/copy.spec.lua | 14 --
src/Set/count.spec.lua | 17 --
src/Set/delete.spec.lua | 23 ---
src/Set/difference.spec.lua | 43 -----
src/Set/differenceSymmetric.spec.lua | 43 -----
src/Set/filter.spec.lua | 28 ---
src/Set/fromArray.spec.lua | 12 --
src/Set/has.spec.lua | 10 --
src/Set/intersection.spec.lua | 16 --
src/Set/isSubset.spec.lua | 11 --
src/Set/isSuperset.spec.lua | 11 --
src/Set/map.spec.lua | 32 ----
src/Set/merge.spec.lua | 33 ----
src/Set/toArray.spec.lua | 25 ---
src/init.lua | 2 +
stylua.toml | 4 +
wally.lock | 237 ++++++++++++++++++++++++-
wally.toml | 10 +-
109 files changed, 312 insertions(+), 2993 deletions(-)
delete mode 100644 .github/workflows/publish.yml
create mode 100644 .luaurc
delete mode 100644 .stylua.toml
delete mode 100644 CHANGELOG.md
delete mode 100644 src/Array/at.spec.lua
delete mode 100644 src/Array/concat.spec.lua
delete mode 100644 src/Array/concatDeep.spec.lua
delete mode 100644 src/Array/copy.spec.lua
delete mode 100644 src/Array/copyDeep.spec.lua
delete mode 100644 src/Array/count.spec.lua
delete mode 100644 src/Array/create.spec.lua
delete mode 100644 src/Array/difference.spec.lua
delete mode 100644 src/Array/differenceSymmetric.spec.lua
delete mode 100644 src/Array/equals.spec.lua
delete mode 100644 src/Array/equalsDeep.spec.lua
delete mode 100644 src/Array/every.spec.lua
delete mode 100644 src/Array/filter.spec.lua
delete mode 100644 src/Array/find.spec.lua
delete mode 100644 src/Array/findLast.spec.lua
delete mode 100644 src/Array/findWhere.spec.lua
delete mode 100644 src/Array/findWhereLast.spec.lua
delete mode 100644 src/Array/first.spec.lua
delete mode 100644 src/Array/flatten.spec.lua
delete mode 100644 src/Array/freeze.spec.lua
delete mode 100644 src/Array/freezeDeep.spec.lua
delete mode 100644 src/Array/includes.spec.lua
delete mode 100644 src/Array/insert.spec.lua
delete mode 100644 src/Array/is.spec.lua
delete mode 100644 src/Array/last.spec.lua
delete mode 100644 src/Array/map.spec.lua
delete mode 100644 src/Array/pop.spec.lua
delete mode 100644 src/Array/push.spec.lua
delete mode 100644 src/Array/reduce.spec.lua
delete mode 100644 src/Array/reduceRight.spec.lua
delete mode 100644 src/Array/removeIndex.spec.lua
delete mode 100644 src/Array/removeIndices.spec.lua
delete mode 100644 src/Array/removeValue.spec.lua
delete mode 100644 src/Array/removeValues.spec.lua
delete mode 100644 src/Array/reverse.spec.lua
delete mode 100644 src/Array/set.spec.lua
delete mode 100644 src/Array/shift.spec.lua
delete mode 100644 src/Array/shuffle.spec.lua
delete mode 100644 src/Array/slice.spec.lua
delete mode 100644 src/Array/some.spec.lua
delete mode 100644 src/Array/sort.spec.lua
delete mode 100644 src/Array/splice.spec.lua
delete mode 100644 src/Array/toSet.spec.lua
delete mode 100644 src/Array/unshift.spec.lua
delete mode 100644 src/Array/update.spec.lua
delete mode 100644 src/Array/zip.spec.lua
delete mode 100644 src/Array/zipAll.spec.lua
delete mode 100644 src/Dictionary/copy.spec.lua
delete mode 100644 src/Dictionary/copyDeep.spec.lua
delete mode 100644 src/Dictionary/count.spec.lua
delete mode 100644 src/Dictionary/entries.spec.lua
delete mode 100644 src/Dictionary/equals.spec.lua
delete mode 100644 src/Dictionary/equalsDeep.spec.lua
delete mode 100644 src/Dictionary/every.spec.lua
delete mode 100644 src/Dictionary/filter.spec.lua
delete mode 100644 src/Dictionary/flatten.spec.lua
delete mode 100644 src/Dictionary/flip.spec.lua
delete mode 100644 src/Dictionary/freeze.spec.lua
delete mode 100644 src/Dictionary/freezeDeep.spec.lua
delete mode 100644 src/Dictionary/fromArrays.spec.lua
delete mode 100644 src/Dictionary/fromEntries.spec.lua
delete mode 100644 src/Dictionary/has.spec.lua
delete mode 100644 src/Dictionary/includes.spec.lua
delete mode 100644 src/Dictionary/keys.spec.lua
delete mode 100644 src/Dictionary/map.spec.lua
delete mode 100644 src/Dictionary/merge.spec.lua
delete mode 100644 src/Dictionary/mergeDeep.spec.lua
delete mode 100644 src/Dictionary/removeKey.spec.lua
delete mode 100644 src/Dictionary/removeKeys.spec.lua
delete mode 100644 src/Dictionary/removeValue.spec.lua
delete mode 100644 src/Dictionary/removeValues.spec.lua
delete mode 100644 src/Dictionary/set.spec.lua
delete mode 100644 src/Dictionary/some.spec.lua
delete mode 100644 src/Dictionary/update.spec.lua
delete mode 100644 src/Dictionary/values.spec.lua
delete mode 100644 src/Dictionary/withKeys.spec.lua
delete mode 100644 src/Set/add.spec.lua
delete mode 100644 src/Set/copy.spec.lua
delete mode 100644 src/Set/count.spec.lua
delete mode 100644 src/Set/delete.spec.lua
delete mode 100644 src/Set/difference.spec.lua
delete mode 100644 src/Set/differenceSymmetric.spec.lua
delete mode 100644 src/Set/filter.spec.lua
delete mode 100644 src/Set/fromArray.spec.lua
delete mode 100644 src/Set/has.spec.lua
delete mode 100644 src/Set/intersection.spec.lua
delete mode 100644 src/Set/isSubset.spec.lua
delete mode 100644 src/Set/isSuperset.spec.lua
delete mode 100644 src/Set/map.spec.lua
delete mode 100644 src/Set/merge.spec.lua
delete mode 100644 src/Set/toArray.spec.lua
create mode 100644 stylua.toml
diff --git a/.gitattributes b/.gitattributes
index dfe0770..9de76e4 100644
--- a/.gitattributes
+++ b/.gitattributes
@@ -1,2 +1,5 @@
# Auto detect text files and perform LF normalization
* text=auto
+
+# Highlight Luau as Lua files
+*.lua linguist-language=Luau
diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml
index 2907ff9..b481a62 100644
--- a/.github/FUNDING.yml
+++ b/.github/FUNDING.yml
@@ -1,3 +1,3 @@
-github: csqrl
+github: cxmeel
custom:
- - "https://roblox.com/groups/9536808/csqrl#!/store"
+ - "https://roblox.com/groups/9536808/cxmeel#!/store"
diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml
deleted file mode 100644
index 6b44ec9..0000000
--- a/.github/workflows/publish.yml
+++ /dev/null
@@ -1,58 +0,0 @@
-name: Publish Package
-
-on:
- workflow_dispatch:
- release:
- types: [published]
-
-jobs:
- publish-package:
- if: ${{ github.events.release.prerelease == false }}
- runs-on: ubuntu-latest
- timeout-minutes: 5
-
- steps:
- - name: Checkout Repository
- uses: actions/checkout@v2
- with:
- ref: ${{ github.event.release.tag_name }}
-
- - name: Setup Aftman
- uses: ok-nick/setup-aftman@v0.3.0
-
- - name: Setup Node LTS
- uses: actions/setup-node@v2
- with:
- node-version: lts/*
-
- - name: Report Tool Versions
- run: |
- aftman -V
- aftman list
- node -v
- npm -v
-
- - name: Install Dependencies
- run: |
- npm install
- wally install
-
- - name: Remove Tests
- run: |
- find . -name "*.spec.lua" -delete
-
- # - name: Publish to Roblox
- # run: rojo upload default.project.json --asset_id "${{ secrets.ASSET_ID }}" --cookie "${{ secrets.ROBLOSECURITY }}"
-
- - name: Publish to Wally
- env:
- WALLY_TOKEN: ${{ secrets.WALLY_TOKEN }}
- run: |
- mkdir -p ~/.wally
- printf "[tokens]\n\"https://api.wally.run/\" = \"%s\"" "$WALLY_TOKEN" >> ~/.wally/auth.toml
- wally publish
-
- - name: Publish to NPM
- uses: JS-DevTools/npm-publish@v1
- with:
- token: ${{ secrets.NPM_TOKEN }}
diff --git a/.gitignore b/.gitignore
index 55b6621..f0deb4d 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,9 +1,13 @@
-*.rbx*
-*.env
+/*.rbx*
+.env
+.env.*
*.tsbuildinfo
-packages/
-node_modules/
-out/
-include/
-build/
+/Packages
+/DevPackages
+/ServerPackages
+/temp
+/node_modules
+/out
+/include
+/build
diff --git a/.luaurc b/.luaurc
new file mode 100644
index 0000000..cfbdb52
--- /dev/null
+++ b/.luaurc
@@ -0,0 +1,8 @@
+{
+ "languageMode": "strict",
+ "lint": { "*": false },
+ "aliases": {
+ "Pkg": "Packages",
+ "DevPkg": "DevPackages"
+ }
+}
diff --git a/.stylua.toml b/.stylua.toml
deleted file mode 100644
index 3ae7657..0000000
--- a/.stylua.toml
+++ /dev/null
@@ -1,7 +0,0 @@
-column_width = 100
-line_endings = "Unix"
-indent_type = "Tabs"
-indent_width = 4
-quote_style = "AutoPreferDouble"
-call_parentheses = "Always"
-collapse_simple_statement = "Never"
diff --git a/CHANGELOG.md b/CHANGELOG.md
deleted file mode 100644
index fb5a513..0000000
--- a/CHANGELOG.md
+++ /dev/null
@@ -1,61 +0,0 @@
-# Changelog
-
-## [0.0.6]
-
-### Added
-
-- `Dictionary.withKeys` by @sasial-dev to restrict what keys can appear in a given dictionary.
-
-## [0.0.5]
-
-### Added
-
-- `Array.difference` and `Array.differenceSymmetric` to find the difference between two or more arrays.
-- `Set.difference` and `Set.differenceSymmetric` to find the difference between two or more sets.
-
-### Fixed
-
-- Typings for `Array.concat`, which previously returned `T[][]` instead of `T[]`.
-
-## [0.0.4]
-
-- Implemented `Array.is: (value: any) -> boolean` to check if a given value is an array.
-
-## [0.0.3]
-
-### Changed
-
-- If `update` is called with a key that doesn't exist in the specified dictionary, the key's value is **set to the key itself**. Fix by [@reselim](https://github.com/Reselim) in [PR #7](https://github.com/csqrl/sift/pull/7).
-- Added `aftman.toml` and switched GitHub workflows over to use aftman.
-
-## [0.0.2]
-
-### Changed
-
-- Fixed a bug where `Array.concat(Deep)`, `Dictionary.merge(Deep)` and `Set.merge` would not accept holes (`nil` values) in their arguments. This would cause the function to stop processing further arguments once it found a `nil` value.
-- Fixed a bug where `Array.insert` would not insert the element at the correct index. An index of `0` will now insert the element at the end of the array. `length+1` will also insert the element at the end of the array. `length+2` (or greater) will be ignored, and the original array will be returned.
-- Bumped tooling versions:
- - rojo to v7.1.1
- - stylua to v0.13.1
- - selene to v0.17.0
-
-## [0.0.1]
-
-### Added
-
-- Basic **TypeScript (roblox-ts) support** (no tsdoc yet)! 🎉
-- Implemented `isEmpty`
-- Added typings to `equalObjects`
-- Added aliases for `Array.concat`, `Array.concatDeep`, `Array.push`, `Array.unshift`, `Array.find`, `Array.includes`, `Dictionary.join`, `Dictionary.joinDeep`, `Set.fromArray`, `Set.merge`, `Set.delete`
-- Added doc pages for installation and usage samples
-
-### Changed
-
-- Exposed `isEmpty` and `equalObjects` from the root module
-- Improved typings for methods accepting predictes
-- Updated documentation for some methods
-- Fixed `Dictionary.flatten` being shown in the `Array` docs (wrong `@within` tag)
-
-## [0.0.0]
-
-Initial development version.
diff --git a/README.md b/README.md
index e748a2e..bb2b1a8 100644
--- a/README.md
+++ b/README.md
@@ -3,30 +3,29 @@
[freddylist/llama]: https://github.com/freddylist/llama
[osyrisrblx/t]: https://github.com/osyrisrblx/t
[upliftgames/moonwave]: https://github.com/upliftgames/moonwave
-[upliftgames/wally]: https://github.com/upliftgames/wally
-[sift]: https://github.com/csqrl/sift
-[sift/releases]: https://github.com/csqrl/sift/releases
-[sift/wally]: https://wally.run/package/csqrl/sift
+[sift]: https://github.com/cxmeel/sift
+[sift/releases]: https://github.com/cxmeel/sift/releases
+[sift/wally]: https://wally.run/package/cxmeel/sift
[sift/roblox]: https://www.roblox.com/library/9486684823
-[sift/itch.io]: https://csqrl.itch.io/sift
+[sift/itch.io]: https://cxmeel.itch.io/sift
[sift/npm]: https://npmjs.com/package/@rbxts/sift
-[shields/github-release]: https://img.shields.io/github/v/release/csqrl/sift?label=latest+release&style=flat
-[shields/wally]: https://img.shields.io/endpoint?url=https://runkit.io/clockworksquirrel/wally-version-shield/branches/master/csqrl/sift&color=blue&label=wally&style=flat
+[shields/github-release]: https://img.shields.io/github/v/release/cxmeel/sift?label=latest+release&style=flat
+[shields/wally]: https://img.shields.io/endpoint?url=https://runkit.io/clockworksquirrel/wally-version-shield/branches/master/cxmeel/sift&color=blue&label=wally&style=flat
[shields/npm]: https://img.shields.io/npm/v/@rbxts/sift?style=flat
-[badges/github]: https://raw.githubusercontent.com/gist/csqrl/56c5f18b229ca1e61feb6eb5fb149f43/raw/githubSource.svg
-[badges/itch]: https://raw.githubusercontent.com/gist/csqrl/56c5f18b229ca1e61feb6eb5fb149f43/raw/itch.svg
-[badges/npm]: https://raw.githubusercontent.com/gist/csqrl/56c5f18b229ca1e61feb6eb5fb149f43/raw/npm.svg
-[badges/roblox]: https://raw.githubusercontent.com/gist/csqrl/56c5f18b229ca1e61feb6eb5fb149f43/raw/roblox.svg
-[badges/roblox-small]: https://raw.githubusercontent.com/gist/csqrl/56c5f18b229ca1e61feb6eb5fb149f43/raw/robloxSmall.svg
+[badges/github]: https://raw.githubusercontent.com/gist/cxmeel/56c5f18b229ca1e61feb6eb5fb149f43/raw/githubSource.svg
+[badges/itch]: https://raw.githubusercontent.com/gist/cxmeel/56c5f18b229ca1e61feb6eb5fb149f43/raw/itch.svg
+[badges/npm]: https://raw.githubusercontent.com/gist/cxmeel/56c5f18b229ca1e61feb6eb5fb149f43/raw/npm.svg
+[badges/roblox]: https://raw.githubusercontent.com/gist/cxmeel/56c5f18b229ca1e61feb6eb5fb149f43/raw/roblox.svg
# Sift
+
[![Source code][badges/github]][sift] [![NPM Package][badges/npm]][sift/npm] [![Itch.io store page][badges/itch]][sift/itch.io] [![Roblox library][badges/roblox]][sift/roblox]
@@ -41,7 +40,7 @@ Heavily based on [@freddylist's Llama][freddylist/llama] library, which is no lo
## Documentation
-Documentation, powered by [moonwave][upliftgames/moonwave], is available at https://csqrl.github.io/sift.
+Documentation, powered by [moonwave][upliftgames/moonwave], is available at
.
## v0.x
@@ -60,17 +59,17 @@ While Sift is 100% free and open source, if you feel like sponsoring, Sift is al
### Wally
-Wally is a CLI package manager (much like NPM, Yarn or Cargo) for Roblox by @UpliftGames. Find out more at https://github.com/upliftgames/wally.
+Wally is a CLI package manager (much like NPM, Yarn or Cargo) for Roblox by @UpliftGames. Find out more at .
```toml
# wally.toml
[dependencies]
-Sift = "csqrl/sift@0.0.X" # Replace with current version number
+Sift = "cxmeel/sift@0.0.X" # Replace with current version number
```
```shell
-$ wally install
+wally install
```
### TypeScript
@@ -78,7 +77,7 @@ $ wally install
v0.0.1 of Sift includes TypeScript typings. This means Sift is now compatible with roblox-ts. Refer to the Luau docs for API details.
```shell
-$ npm install @rbxts/sift
+npm install @rbxts/sift
```
```ts
diff --git a/aftman.toml b/aftman.toml
index 3cafc84..3faee9f 100644
--- a/aftman.toml
+++ b/aftman.toml
@@ -1,6 +1,13 @@
+# This file lists tools managed by Aftman, a cross-platform toolchain manager.
+# For more information, see https://github.com/LPGhatguy/aftman
+
+# To add a new tool, add an entry to this table.
[tools]
-rojo = "rojo-rbx/rojo@7.3.0"
+darklua = "seaofvoices/darklua@0.12.1"
+luau-lsp = "johnnymorganz/luau-lsp@1.28.1"
+# lune = "filiptibell/lune@0.8.0"
+rojo = "rojo-rbx/rojo@7.4.1"
run-in-roblox = "rojo-rbx/run-in-roblox@0.3.0"
+selene = "kampfkarren/selene@0.26.1"
+stylua = "johnnymorganz/stylua@0.20.0"
wally = "upliftgames/wally@0.3.2"
-stylua = "johnnymorganz/stylua@0.18.1"
-selene = "kampfkarren/selene@0.25.0"
diff --git a/default.project.json b/default.project.json
index 91c96e9..43954a7 100644
--- a/default.project.json
+++ b/default.project.json
@@ -1,6 +1,9 @@
{
"name": "Sift",
"tree": {
- "$path": "src"
+ "$path": "src",
+ "Metadata": {
+ "$path": "wally.toml"
+ }
}
}
diff --git a/docs/Installation.md b/docs/Installation.md
index 5641fde..1756841 100644
--- a/docs/Installation.md
+++ b/docs/Installation.md
@@ -4,11 +4,11 @@ sidebar_position: 2
-[sift]: https://github.com/csqrl/sift
-[sift/releases]: https://github.com/csqrl/sift/releases
-[sift/wally]: https://wally.run/package/csqrl/sift
+[sift]: https://github.com/cxmeel/sift
+[sift/releases]: https://github.com/cxmeel/sift/releases
+[sift/wally]: https://wally.run/package/cxmeel/sift
[sift/roblox]: https://www.roblox.com/library/9486684823
-[sift/itch.io]: https://csqrl.itch.io/sift
+[sift/itch.io]: https://cxmeel.itch.io/sift
[sift/npm]: https://npmjs.com/package/@rbxts/sift
Sift is available from [Wally][sift/wally], [Itch.io][sift/itch.io], the [Roblox Library][sift/roblox], and [GitHub releases][sift/releases].
@@ -23,7 +23,7 @@ Wally is a CLI package manager (much like NPM, Yarn or Cargo) for Roblox by @Upl
# wally.toml
[dependencies]
-Sift = "csqrl/sift@=0.0.1"
+Sift = "cxmeel/sift@=0.0.1"
```
```shell
diff --git a/moonwave.toml b/moonwave.toml
index 2a40967..9b18c75 100644
--- a/moonwave.toml
+++ b/moonwave.toml
@@ -1,16 +1,14 @@
title = "Sift"
gitSourceBranch = "main"
-changelog = true
classOrder = ["Sift"]
[home]
-# enabled = true
includeReadme = true
[[navbar.items]]
label = "Sponsor"
-href = "https://github.com/sponsors/csqrl"
+href = "https://github.com/sponsors/cxmeel"
position = "right"
[docusaurus.themeConfig.colorMode]
diff --git a/package.json b/package.json
index 5d506bc..9591aca 100644
--- a/package.json
+++ b/package.json
@@ -15,7 +15,7 @@
},
"repository": {
"type": "git",
- "url": "git+https://github.com/csqrl/sift.git"
+ "url": "git+https://github.com/cxmeel/sift.git"
},
"keywords": [
"array",
@@ -29,9 +29,9 @@
],
"license": "MIT",
"bugs": {
- "url": "https://github.com/csqrl/sift/issues"
+ "url": "https://github.com/cxmeel/sift/issues"
},
- "homepage": "https://csqrl.github.io/sift",
+ "homepage": "https://cxmeel.github.io/sift",
"files": [
"out",
"!**/*.tsbuildinfo"
@@ -42,7 +42,6 @@
"rbxts-transform-debug": "^1.0.0-rc.1",
"rbxts-transform-env": "^1.0.0-rc.0",
"typescript": "^4.3.5",
- "roblox-ts": "^1.2.7",
- "husky": "^8.0.0"
+ "roblox-ts": "^1.2.7"
}
}
diff --git a/sourcemap.json b/sourcemap.json
index 7f9fa46..b17927f 100644
--- a/sourcemap.json
+++ b/sourcemap.json
@@ -1 +1 @@
-{"name":"Sift","className":"ModuleScript","filePaths":["src\\init.lua","default.project.json"],"children":[{"name":"Array","className":"ModuleScript","filePaths":["src\\Array\\init.lua"],"children":[{"name":"at","className":"ModuleScript","filePaths":["src\\Array\\at.lua"]},{"name":"at.spec","className":"ModuleScript","filePaths":["src\\Array\\at.spec.lua"]},{"name":"concat","className":"ModuleScript","filePaths":["src\\Array\\concat.lua"]},{"name":"concat.spec","className":"ModuleScript","filePaths":["src\\Array\\concat.spec.lua"]},{"name":"concatDeep","className":"ModuleScript","filePaths":["src\\Array\\concatDeep.lua"]},{"name":"concatDeep.spec","className":"ModuleScript","filePaths":["src\\Array\\concatDeep.spec.lua"]},{"name":"copy","className":"ModuleScript","filePaths":["src\\Array\\copy.lua"]},{"name":"copy.spec","className":"ModuleScript","filePaths":["src\\Array\\copy.spec.lua"]},{"name":"copyDeep","className":"ModuleScript","filePaths":["src\\Array\\copyDeep.lua"]},{"name":"copyDeep.spec","className":"ModuleScript","filePaths":["src\\Array\\copyDeep.spec.lua"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Array\\count.lua"]},{"name":"count.spec","className":"ModuleScript","filePaths":["src\\Array\\count.spec.lua"]},{"name":"create","className":"ModuleScript","filePaths":["src\\Array\\create.lua"]},{"name":"create.spec","className":"ModuleScript","filePaths":["src\\Array\\create.spec.lua"]},{"name":"difference","className":"ModuleScript","filePaths":["src\\Array\\difference.lua"]},{"name":"difference.spec","className":"ModuleScript","filePaths":["src\\Array\\difference.spec.lua"]},{"name":"differenceSymmetric","className":"ModuleScript","filePaths":["src\\Array\\differenceSymmetric.lua"]},{"name":"differenceSymmetric.spec","className":"ModuleScript","filePaths":["src\\Array\\differenceSymmetric.spec.lua"]},{"name":"equals","className":"ModuleScript","filePaths":["src\\Array\\equals.lua"]},{"name":"equals.spec","className":"ModuleScript","filePaths":["src\\Array\\equals.spec.lua"]},{"name":"equalsDeep","className":"ModuleScript","filePaths":["src\\Array\\equalsDeep.lua"]},{"name":"equalsDeep.spec","className":"ModuleScript","filePaths":["src\\Array\\equalsDeep.spec.lua"]},{"name":"every","className":"ModuleScript","filePaths":["src\\Array\\every.lua"]},{"name":"every.spec","className":"ModuleScript","filePaths":["src\\Array\\every.spec.lua"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Array\\filter.lua"]},{"name":"filter.spec","className":"ModuleScript","filePaths":["src\\Array\\filter.spec.lua"]},{"name":"find","className":"ModuleScript","filePaths":["src\\Array\\find.lua"]},{"name":"find.spec","className":"ModuleScript","filePaths":["src\\Array\\find.spec.lua"]},{"name":"findLast","className":"ModuleScript","filePaths":["src\\Array\\findLast.lua"]},{"name":"findLast.spec","className":"ModuleScript","filePaths":["src\\Array\\findLast.spec.lua"]},{"name":"findWhere","className":"ModuleScript","filePaths":["src\\Array\\findWhere.lua"]},{"name":"findWhere.spec","className":"ModuleScript","filePaths":["src\\Array\\findWhere.spec.lua"]},{"name":"findWhereLast","className":"ModuleScript","filePaths":["src\\Array\\findWhereLast.lua"]},{"name":"findWhereLast.spec","className":"ModuleScript","filePaths":["src\\Array\\findWhereLast.spec.lua"]},{"name":"first","className":"ModuleScript","filePaths":["src\\Array\\first.lua"]},{"name":"first.spec","className":"ModuleScript","filePaths":["src\\Array\\first.spec.lua"]},{"name":"flatten","className":"ModuleScript","filePaths":["src\\Array\\flatten.lua"]},{"name":"flatten.spec","className":"ModuleScript","filePaths":["src\\Array\\flatten.spec.lua"]},{"name":"freeze","className":"ModuleScript","filePaths":["src\\Array\\freeze.lua"]},{"name":"freeze.spec","className":"ModuleScript","filePaths":["src\\Array\\freeze.spec.lua"]},{"name":"freezeDeep","className":"ModuleScript","filePaths":["src\\Array\\freezeDeep.lua"]},{"name":"freezeDeep.spec","className":"ModuleScript","filePaths":["src\\Array\\freezeDeep.spec.lua"]},{"name":"includes","className":"ModuleScript","filePaths":["src\\Array\\includes.lua"]},{"name":"includes.spec","className":"ModuleScript","filePaths":["src\\Array\\includes.spec.lua"]},{"name":"insert","className":"ModuleScript","filePaths":["src\\Array\\insert.lua"]},{"name":"insert.spec","className":"ModuleScript","filePaths":["src\\Array\\insert.spec.lua"]},{"name":"is","className":"ModuleScript","filePaths":["src\\Array\\is.lua"]},{"name":"is.spec","className":"ModuleScript","filePaths":["src\\Array\\is.spec.lua"]},{"name":"last","className":"ModuleScript","filePaths":["src\\Array\\last.lua"]},{"name":"last.spec","className":"ModuleScript","filePaths":["src\\Array\\last.spec.lua"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Array\\map.lua"]},{"name":"map.spec","className":"ModuleScript","filePaths":["src\\Array\\map.spec.lua"]},{"name":"pop","className":"ModuleScript","filePaths":["src\\Array\\pop.lua"]},{"name":"pop.spec","className":"ModuleScript","filePaths":["src\\Array\\pop.spec.lua"]},{"name":"push","className":"ModuleScript","filePaths":["src\\Array\\push.lua"]},{"name":"push.spec","className":"ModuleScript","filePaths":["src\\Array\\push.spec.lua"]},{"name":"reduce","className":"ModuleScript","filePaths":["src\\Array\\reduce.lua"]},{"name":"reduce.spec","className":"ModuleScript","filePaths":["src\\Array\\reduce.spec.lua"]},{"name":"reduceRight","className":"ModuleScript","filePaths":["src\\Array\\reduceRight.lua"]},{"name":"reduceRight.spec","className":"ModuleScript","filePaths":["src\\Array\\reduceRight.spec.lua"]},{"name":"removeIndex","className":"ModuleScript","filePaths":["src\\Array\\removeIndex.lua"]},{"name":"removeIndex.spec","className":"ModuleScript","filePaths":["src\\Array\\removeIndex.spec.lua"]},{"name":"removeIndices","className":"ModuleScript","filePaths":["src\\Array\\removeIndices.lua"]},{"name":"removeIndices.spec","className":"ModuleScript","filePaths":["src\\Array\\removeIndices.spec.lua"]},{"name":"removeValue","className":"ModuleScript","filePaths":["src\\Array\\removeValue.lua"]},{"name":"removeValue.spec","className":"ModuleScript","filePaths":["src\\Array\\removeValue.spec.lua"]},{"name":"removeValues","className":"ModuleScript","filePaths":["src\\Array\\removeValues.lua"]},{"name":"removeValues.spec","className":"ModuleScript","filePaths":["src\\Array\\removeValues.spec.lua"]},{"name":"reverse","className":"ModuleScript","filePaths":["src\\Array\\reverse.lua"]},{"name":"reverse.spec","className":"ModuleScript","filePaths":["src\\Array\\reverse.spec.lua"]},{"name":"set","className":"ModuleScript","filePaths":["src\\Array\\set.lua"]},{"name":"set.spec","className":"ModuleScript","filePaths":["src\\Array\\set.spec.lua"]},{"name":"shift","className":"ModuleScript","filePaths":["src\\Array\\shift.lua"]},{"name":"shift.spec","className":"ModuleScript","filePaths":["src\\Array\\shift.spec.lua"]},{"name":"shuffle","className":"ModuleScript","filePaths":["src\\Array\\shuffle.lua"]},{"name":"shuffle.spec","className":"ModuleScript","filePaths":["src\\Array\\shuffle.spec.lua"]},{"name":"slice","className":"ModuleScript","filePaths":["src\\Array\\slice.lua"]},{"name":"slice.spec","className":"ModuleScript","filePaths":["src\\Array\\slice.spec.lua"]},{"name":"some","className":"ModuleScript","filePaths":["src\\Array\\some.lua"]},{"name":"some.spec","className":"ModuleScript","filePaths":["src\\Array\\some.spec.lua"]},{"name":"sort","className":"ModuleScript","filePaths":["src\\Array\\sort.lua"]},{"name":"sort.spec","className":"ModuleScript","filePaths":["src\\Array\\sort.spec.lua"]},{"name":"splice","className":"ModuleScript","filePaths":["src\\Array\\splice.lua"]},{"name":"splice.spec","className":"ModuleScript","filePaths":["src\\Array\\splice.spec.lua"]},{"name":"toSet","className":"ModuleScript","filePaths":["src\\Array\\toSet.lua"]},{"name":"toSet.spec","className":"ModuleScript","filePaths":["src\\Array\\toSet.spec.lua"]},{"name":"unshift","className":"ModuleScript","filePaths":["src\\Array\\unshift.lua"]},{"name":"unshift.spec","className":"ModuleScript","filePaths":["src\\Array\\unshift.spec.lua"]},{"name":"update","className":"ModuleScript","filePaths":["src\\Array\\update.lua"]},{"name":"update.spec","className":"ModuleScript","filePaths":["src\\Array\\update.spec.lua"]},{"name":"zip","className":"ModuleScript","filePaths":["src\\Array\\zip.lua"]},{"name":"zip.spec","className":"ModuleScript","filePaths":["src\\Array\\zip.spec.lua"]},{"name":"zipAll","className":"ModuleScript","filePaths":["src\\Array\\zipAll.lua"]},{"name":"zipAll.spec","className":"ModuleScript","filePaths":["src\\Array\\zipAll.spec.lua"]}]},{"name":"Dictionary","className":"ModuleScript","filePaths":["src\\Dictionary\\init.lua"],"children":[{"name":"copy","className":"ModuleScript","filePaths":["src\\Dictionary\\copy.lua"]},{"name":"copy.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\copy.spec.lua"]},{"name":"copyDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\copyDeep.lua"]},{"name":"copyDeep.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\copyDeep.spec.lua"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Dictionary\\count.lua"]},{"name":"count.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\count.spec.lua"]},{"name":"entries","className":"ModuleScript","filePaths":["src\\Dictionary\\entries.lua"]},{"name":"entries.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\entries.spec.lua"]},{"name":"equals","className":"ModuleScript","filePaths":["src\\Dictionary\\equals.lua"]},{"name":"equals.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\equals.spec.lua"]},{"name":"equalsDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\equalsDeep.lua"]},{"name":"equalsDeep.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\equalsDeep.spec.lua"]},{"name":"every","className":"ModuleScript","filePaths":["src\\Dictionary\\every.lua"]},{"name":"every.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\every.spec.lua"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Dictionary\\filter.lua"]},{"name":"filter.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\filter.spec.lua"]},{"name":"flatten","className":"ModuleScript","filePaths":["src\\Dictionary\\flatten.lua"]},{"name":"flatten.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\flatten.spec.lua"]},{"name":"flip","className":"ModuleScript","filePaths":["src\\Dictionary\\flip.lua"]},{"name":"flip.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\flip.spec.lua"]},{"name":"freeze","className":"ModuleScript","filePaths":["src\\Dictionary\\freeze.lua"]},{"name":"freeze.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\freeze.spec.lua"]},{"name":"freezeDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\freezeDeep.lua"]},{"name":"freezeDeep.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\freezeDeep.spec.lua"]},{"name":"fromArrays","className":"ModuleScript","filePaths":["src\\Dictionary\\fromArrays.lua"]},{"name":"fromArrays.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\fromArrays.spec.lua"]},{"name":"fromEntries","className":"ModuleScript","filePaths":["src\\Dictionary\\fromEntries.lua"]},{"name":"fromEntries.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\fromEntries.spec.lua"]},{"name":"has","className":"ModuleScript","filePaths":["src\\Dictionary\\has.lua"]},{"name":"has.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\has.spec.lua"]},{"name":"includes","className":"ModuleScript","filePaths":["src\\Dictionary\\includes.lua"]},{"name":"includes.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\includes.spec.lua"]},{"name":"keys","className":"ModuleScript","filePaths":["src\\Dictionary\\keys.lua"]},{"name":"keys.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\keys.spec.lua"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Dictionary\\map.lua"]},{"name":"map.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\map.spec.lua"]},{"name":"merge","className":"ModuleScript","filePaths":["src\\Dictionary\\merge.lua"]},{"name":"merge.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\merge.spec.lua"]},{"name":"mergeDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\mergeDeep.lua"]},{"name":"mergeDeep.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\mergeDeep.spec.lua"]},{"name":"removeKey","className":"ModuleScript","filePaths":["src\\Dictionary\\removeKey.lua"]},{"name":"removeKey.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\removeKey.spec.lua"]},{"name":"removeKeys","className":"ModuleScript","filePaths":["src\\Dictionary\\removeKeys.lua"]},{"name":"removeKeys.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\removeKeys.spec.lua"]},{"name":"removeValue","className":"ModuleScript","filePaths":["src\\Dictionary\\removeValue.lua"]},{"name":"removeValue.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\removeValue.spec.lua"]},{"name":"removeValues","className":"ModuleScript","filePaths":["src\\Dictionary\\removeValues.lua"]},{"name":"removeValues.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\removeValues.spec.lua"]},{"name":"set","className":"ModuleScript","filePaths":["src\\Dictionary\\set.lua"]},{"name":"set.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\set.spec.lua"]},{"name":"some","className":"ModuleScript","filePaths":["src\\Dictionary\\some.lua"]},{"name":"some.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\some.spec.lua"]},{"name":"update","className":"ModuleScript","filePaths":["src\\Dictionary\\update.lua"]},{"name":"update.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\update.spec.lua"]},{"name":"values","className":"ModuleScript","filePaths":["src\\Dictionary\\values.lua"]},{"name":"values.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\values.spec.lua"]},{"name":"withKeys","className":"ModuleScript","filePaths":["src\\Dictionary\\withKeys.lua"]},{"name":"withKeys.spec","className":"ModuleScript","filePaths":["src\\Dictionary\\withKeys.spec.lua"]}]},{"name":"None","className":"ModuleScript","filePaths":["src\\None.lua"]},{"name":"Set","className":"ModuleScript","filePaths":["src\\Set\\init.lua"],"children":[{"name":"add","className":"ModuleScript","filePaths":["src\\Set\\add.lua"]},{"name":"add.spec","className":"ModuleScript","filePaths":["src\\Set\\add.spec.lua"]},{"name":"copy","className":"ModuleScript","filePaths":["src\\Set\\copy.lua"]},{"name":"copy.spec","className":"ModuleScript","filePaths":["src\\Set\\copy.spec.lua"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Set\\count.lua"]},{"name":"count.spec","className":"ModuleScript","filePaths":["src\\Set\\count.spec.lua"]},{"name":"delete","className":"ModuleScript","filePaths":["src\\Set\\delete.lua"]},{"name":"delete.spec","className":"ModuleScript","filePaths":["src\\Set\\delete.spec.lua"]},{"name":"difference","className":"ModuleScript","filePaths":["src\\Set\\difference.lua"]},{"name":"difference.spec","className":"ModuleScript","filePaths":["src\\Set\\difference.spec.lua"]},{"name":"differenceSymmetric","className":"ModuleScript","filePaths":["src\\Set\\differenceSymmetric.lua"]},{"name":"differenceSymmetric.spec","className":"ModuleScript","filePaths":["src\\Set\\differenceSymmetric.spec.lua"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Set\\filter.lua"]},{"name":"filter.spec","className":"ModuleScript","filePaths":["src\\Set\\filter.spec.lua"]},{"name":"fromArray","className":"ModuleScript","filePaths":["src\\Set\\fromArray.lua"]},{"name":"fromArray.spec","className":"ModuleScript","filePaths":["src\\Set\\fromArray.spec.lua"]},{"name":"has","className":"ModuleScript","filePaths":["src\\Set\\has.lua"]},{"name":"has.spec","className":"ModuleScript","filePaths":["src\\Set\\has.spec.lua"]},{"name":"intersection","className":"ModuleScript","filePaths":["src\\Set\\intersection.lua"]},{"name":"intersection.spec","className":"ModuleScript","filePaths":["src\\Set\\intersection.spec.lua"]},{"name":"isSubset","className":"ModuleScript","filePaths":["src\\Set\\isSubset.lua"]},{"name":"isSubset.spec","className":"ModuleScript","filePaths":["src\\Set\\isSubset.spec.lua"]},{"name":"isSuperset","className":"ModuleScript","filePaths":["src\\Set\\isSuperset.lua"]},{"name":"isSuperset.spec","className":"ModuleScript","filePaths":["src\\Set\\isSuperset.spec.lua"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Set\\map.lua"]},{"name":"map.spec","className":"ModuleScript","filePaths":["src\\Set\\map.spec.lua"]},{"name":"merge","className":"ModuleScript","filePaths":["src\\Set\\merge.lua"]},{"name":"merge.spec","className":"ModuleScript","filePaths":["src\\Set\\merge.spec.lua"]},{"name":"toArray","className":"ModuleScript","filePaths":["src\\Set\\toArray.lua"]},{"name":"toArray.spec","className":"ModuleScript","filePaths":["src\\Set\\toArray.spec.lua"]}]},{"name":"Types","className":"ModuleScript","filePaths":["src\\Types.lua"]},{"name":"Util","className":"ModuleScript","filePaths":["src\\Util\\init.lua"],"children":[{"name":"equalObjects","className":"ModuleScript","filePaths":["src\\Util\\equalObjects.lua"]},{"name":"func","className":"ModuleScript","filePaths":["src\\Util\\func.lua"]},{"name":"isEmpty","className":"ModuleScript","filePaths":["src\\Util\\isEmpty.lua"]}]}]}
\ No newline at end of file
+{"name":"Sift","className":"ModuleScript","filePaths":["src\\init.lua","default.project.json"],"children":[{"name":"Array","className":"ModuleScript","filePaths":["src\\Array\\init.lua"],"children":[{"name":"at","className":"ModuleScript","filePaths":["src\\Array\\at.lua"]},{"name":"concat","className":"ModuleScript","filePaths":["src\\Array\\concat.lua"]},{"name":"concatDeep","className":"ModuleScript","filePaths":["src\\Array\\concatDeep.lua"]},{"name":"copy","className":"ModuleScript","filePaths":["src\\Array\\copy.lua"]},{"name":"copyDeep","className":"ModuleScript","filePaths":["src\\Array\\copyDeep.lua"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Array\\count.lua"]},{"name":"create","className":"ModuleScript","filePaths":["src\\Array\\create.lua"]},{"name":"difference","className":"ModuleScript","filePaths":["src\\Array\\difference.lua"]},{"name":"differenceSymmetric","className":"ModuleScript","filePaths":["src\\Array\\differenceSymmetric.lua"]},{"name":"equals","className":"ModuleScript","filePaths":["src\\Array\\equals.lua"]},{"name":"equalsDeep","className":"ModuleScript","filePaths":["src\\Array\\equalsDeep.lua"]},{"name":"every","className":"ModuleScript","filePaths":["src\\Array\\every.lua"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Array\\filter.lua"]},{"name":"find","className":"ModuleScript","filePaths":["src\\Array\\find.lua"]},{"name":"findLast","className":"ModuleScript","filePaths":["src\\Array\\findLast.lua"]},{"name":"findWhere","className":"ModuleScript","filePaths":["src\\Array\\findWhere.lua"]},{"name":"findWhereLast","className":"ModuleScript","filePaths":["src\\Array\\findWhereLast.lua"]},{"name":"first","className":"ModuleScript","filePaths":["src\\Array\\first.lua"]},{"name":"flatten","className":"ModuleScript","filePaths":["src\\Array\\flatten.lua"]},{"name":"freeze","className":"ModuleScript","filePaths":["src\\Array\\freeze.lua"]},{"name":"freezeDeep","className":"ModuleScript","filePaths":["src\\Array\\freezeDeep.lua"]},{"name":"includes","className":"ModuleScript","filePaths":["src\\Array\\includes.lua"]},{"name":"insert","className":"ModuleScript","filePaths":["src\\Array\\insert.lua"]},{"name":"is","className":"ModuleScript","filePaths":["src\\Array\\is.lua"]},{"name":"last","className":"ModuleScript","filePaths":["src\\Array\\last.lua"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Array\\map.lua"]},{"name":"pop","className":"ModuleScript","filePaths":["src\\Array\\pop.lua"]},{"name":"push","className":"ModuleScript","filePaths":["src\\Array\\push.lua"]},{"name":"reduce","className":"ModuleScript","filePaths":["src\\Array\\reduce.lua"]},{"name":"reduceRight","className":"ModuleScript","filePaths":["src\\Array\\reduceRight.lua"]},{"name":"removeIndex","className":"ModuleScript","filePaths":["src\\Array\\removeIndex.lua"]},{"name":"removeIndices","className":"ModuleScript","filePaths":["src\\Array\\removeIndices.lua"]},{"name":"removeValue","className":"ModuleScript","filePaths":["src\\Array\\removeValue.lua"]},{"name":"removeValues","className":"ModuleScript","filePaths":["src\\Array\\removeValues.lua"]},{"name":"reverse","className":"ModuleScript","filePaths":["src\\Array\\reverse.lua"]},{"name":"set","className":"ModuleScript","filePaths":["src\\Array\\set.lua"]},{"name":"shift","className":"ModuleScript","filePaths":["src\\Array\\shift.lua"]},{"name":"shuffle","className":"ModuleScript","filePaths":["src\\Array\\shuffle.lua"]},{"name":"slice","className":"ModuleScript","filePaths":["src\\Array\\slice.lua"]},{"name":"some","className":"ModuleScript","filePaths":["src\\Array\\some.lua"]},{"name":"sort","className":"ModuleScript","filePaths":["src\\Array\\sort.lua"]},{"name":"splice","className":"ModuleScript","filePaths":["src\\Array\\splice.lua"]},{"name":"toSet","className":"ModuleScript","filePaths":["src\\Array\\toSet.lua"]},{"name":"unshift","className":"ModuleScript","filePaths":["src\\Array\\unshift.lua"]},{"name":"update","className":"ModuleScript","filePaths":["src\\Array\\update.lua"]},{"name":"zip","className":"ModuleScript","filePaths":["src\\Array\\zip.lua"]},{"name":"zipAll","className":"ModuleScript","filePaths":["src\\Array\\zipAll.lua"]}]},{"name":"Dictionary","className":"ModuleScript","filePaths":["src\\Dictionary\\init.lua"],"children":[{"name":"copy","className":"ModuleScript","filePaths":["src\\Dictionary\\copy.lua"]},{"name":"copyDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\copyDeep.lua"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Dictionary\\count.lua"]},{"name":"entries","className":"ModuleScript","filePaths":["src\\Dictionary\\entries.lua"]},{"name":"equals","className":"ModuleScript","filePaths":["src\\Dictionary\\equals.lua"]},{"name":"equalsDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\equalsDeep.lua"]},{"name":"every","className":"ModuleScript","filePaths":["src\\Dictionary\\every.lua"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Dictionary\\filter.lua"]},{"name":"flatten","className":"ModuleScript","filePaths":["src\\Dictionary\\flatten.lua"]},{"name":"flip","className":"ModuleScript","filePaths":["src\\Dictionary\\flip.lua"]},{"name":"freeze","className":"ModuleScript","filePaths":["src\\Dictionary\\freeze.lua"]},{"name":"freezeDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\freezeDeep.lua"]},{"name":"fromArrays","className":"ModuleScript","filePaths":["src\\Dictionary\\fromArrays.lua"]},{"name":"fromEntries","className":"ModuleScript","filePaths":["src\\Dictionary\\fromEntries.lua"]},{"name":"has","className":"ModuleScript","filePaths":["src\\Dictionary\\has.lua"]},{"name":"includes","className":"ModuleScript","filePaths":["src\\Dictionary\\includes.lua"]},{"name":"keys","className":"ModuleScript","filePaths":["src\\Dictionary\\keys.lua"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Dictionary\\map.lua"]},{"name":"merge","className":"ModuleScript","filePaths":["src\\Dictionary\\merge.lua"]},{"name":"mergeDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\mergeDeep.lua"]},{"name":"removeKey","className":"ModuleScript","filePaths":["src\\Dictionary\\removeKey.lua"]},{"name":"removeKeys","className":"ModuleScript","filePaths":["src\\Dictionary\\removeKeys.lua"]},{"name":"removeValue","className":"ModuleScript","filePaths":["src\\Dictionary\\removeValue.lua"]},{"name":"removeValues","className":"ModuleScript","filePaths":["src\\Dictionary\\removeValues.lua"]},{"name":"set","className":"ModuleScript","filePaths":["src\\Dictionary\\set.lua"]},{"name":"some","className":"ModuleScript","filePaths":["src\\Dictionary\\some.lua"]},{"name":"update","className":"ModuleScript","filePaths":["src\\Dictionary\\update.lua"]},{"name":"values","className":"ModuleScript","filePaths":["src\\Dictionary\\values.lua"]},{"name":"withKeys","className":"ModuleScript","filePaths":["src\\Dictionary\\withKeys.lua"]}]},{"name":"None","className":"ModuleScript","filePaths":["src\\None.lua"]},{"name":"Set","className":"ModuleScript","filePaths":["src\\Set\\init.lua"],"children":[{"name":"add","className":"ModuleScript","filePaths":["src\\Set\\add.lua"]},{"name":"copy","className":"ModuleScript","filePaths":["src\\Set\\copy.lua"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Set\\count.lua"]},{"name":"delete","className":"ModuleScript","filePaths":["src\\Set\\delete.lua"]},{"name":"difference","className":"ModuleScript","filePaths":["src\\Set\\difference.lua"]},{"name":"differenceSymmetric","className":"ModuleScript","filePaths":["src\\Set\\differenceSymmetric.lua"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Set\\filter.lua"]},{"name":"fromArray","className":"ModuleScript","filePaths":["src\\Set\\fromArray.lua"]},{"name":"has","className":"ModuleScript","filePaths":["src\\Set\\has.lua"]},{"name":"intersection","className":"ModuleScript","filePaths":["src\\Set\\intersection.lua"]},{"name":"isSubset","className":"ModuleScript","filePaths":["src\\Set\\isSubset.lua"]},{"name":"isSuperset","className":"ModuleScript","filePaths":["src\\Set\\isSuperset.lua"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Set\\map.lua"]},{"name":"merge","className":"ModuleScript","filePaths":["src\\Set\\merge.lua"]},{"name":"toArray","className":"ModuleScript","filePaths":["src\\Set\\toArray.lua"]}]},{"name":"Types","className":"ModuleScript","filePaths":["src\\Types.lua"]},{"name":"Util","className":"ModuleScript","filePaths":["src\\Util\\init.lua"],"children":[{"name":"equalObjects","className":"ModuleScript","filePaths":["src\\Util\\equalObjects.lua"]},{"name":"func","className":"ModuleScript","filePaths":["src\\Util\\func.lua"]},{"name":"isEmpty","className":"ModuleScript","filePaths":["src\\Util\\isEmpty.lua"]}]},{"name":"Metadata","className":"ModuleScript","filePaths":["wally.toml"]}]}
\ No newline at end of file
diff --git a/src/Array/at.spec.lua b/src/Array/at.spec.lua
deleted file mode 100644
index 668cea5..0000000
--- a/src/Array/at.spec.lua
+++ /dev/null
@@ -1,25 +0,0 @@
-return function()
- local At = require(script.Parent.at)
-
- it("should return the value at the given index", function()
- local array = { 1, 2, 3 }
-
- expect(At(array, 1)).to.equal(1)
- expect(At(array, 2)).to.equal(2)
- expect(At(array, 3)).to.equal(3)
- end)
-
- it("should return nil if the index is out of bounds", function()
- local array = { 1, 2, 3 }
-
- expect(At(array, 4)).to.equal(nil)
- end)
-
- it("should return from the end if the index is negative (or 0)", function()
- local array = { 1, 2, 3 }
-
- expect(At(array, 0)).to.equal(3)
- expect(At(array, -1)).to.equal(2)
- expect(At(array, -2)).to.equal(1)
- end)
-end
diff --git a/src/Array/concat.spec.lua b/src/Array/concat.spec.lua
deleted file mode 100644
index a689f9b..0000000
--- a/src/Array/concat.spec.lua
+++ /dev/null
@@ -1,53 +0,0 @@
-return function()
- local Concat = require(script.Parent.concat)
-
- it("should join multiple arrays together into a single array", function()
- local table1 = { 1, 2, 3 }
- local table2 = { 4, 5, 6 }
-
- local new = Concat(table1, table2)
-
- expect(new).to.be.a("table")
-
- expect(new[1]).to.equal(1)
- expect(new[2]).to.equal(2)
- expect(new[3]).to.equal(3)
- expect(new[4]).to.equal(4)
- expect(new[5]).to.equal(5)
- expect(new[6]).to.equal(6)
- end)
-
- it("should return an empty array if no arrays are given", function()
- local new = Concat()
-
- expect(new).to.be.a("table")
- expect(#new).to.equal(0)
- end)
-
- it("should accept nil values", function()
- local new = Concat(nil, { 1, 2, 3 })
- local new2 = Concat({ 1, 2, 3 }, nil)
-
- expect(new).to.be.a("table")
- expect(#new).to.equal(3)
-
- expect(new2).to.be.a("table")
- expect(#new2).to.equal(3)
- end)
-
- it("should not copy the nested arrays", function()
- local table1 = { 1, 2, { 3, 4 } }
- local table2 = { 5, 6, { 7, 8 } }
-
- local new = Concat(table1, table2)
-
- expect(new).to.be.a("table")
-
- expect(new[1]).to.equal(1)
- expect(new[2]).to.equal(2)
- expect(new[3]).to.equal(table1[3])
- expect(new[4]).to.equal(5)
- expect(new[5]).to.equal(6)
- expect(new[6]).to.equal(table2[3])
- end)
-end
diff --git a/src/Array/concatDeep.spec.lua b/src/Array/concatDeep.spec.lua
deleted file mode 100644
index 679c2e0..0000000
--- a/src/Array/concatDeep.spec.lua
+++ /dev/null
@@ -1,53 +0,0 @@
-return function()
- local ConcatDeep = require(script.Parent.concatDeep)
-
- it("should join multiple arrays together into a single array", function()
- local table1 = { 1, 2, 3 }
- local table2 = { 4, 5, 6 }
-
- local new = ConcatDeep(table1, table2)
-
- expect(new).to.be.a("table")
-
- expect(new[1]).to.equal(1)
- expect(new[2]).to.equal(2)
- expect(new[3]).to.equal(3)
- expect(new[4]).to.equal(4)
- expect(new[5]).to.equal(5)
- expect(new[6]).to.equal(6)
- end)
-
- it("should return an empty array if no arrays are given", function()
- local new = ConcatDeep()
-
- expect(new).to.be.a("table")
- expect(#new).to.equal(0)
- end)
-
- it("should accept nil values", function()
- local new = ConcatDeep(nil, { 1, 2, 3 })
- local new2 = ConcatDeep({ 1, 2, 3 }, nil)
-
- expect(new).to.be.a("table")
- expect(#new).to.equal(3)
-
- expect(new2).to.be.a("table")
- expect(#new2).to.equal(3)
- end)
-
- it("should join multiple arrays, copying nested arrays", function()
- local table1 = { 1, 2, { 3, 4 } }
- local table2 = { 5, 6, { 7, 8 } }
-
- local new = ConcatDeep(table1, table2)
-
- expect(new).to.be.a("table")
-
- expect(new[1]).to.equal(1)
- expect(new[2]).to.equal(2)
- expect(new[3]).never.to.equal(table1[3])
- expect(new[4]).to.equal(5)
- expect(new[5]).to.equal(6)
- expect(new[6]).never.to.equal(table2[3])
- end)
-end
diff --git a/src/Array/copy.spec.lua b/src/Array/copy.spec.lua
deleted file mode 100644
index a734e5e..0000000
--- a/src/Array/copy.spec.lua
+++ /dev/null
@@ -1,29 +0,0 @@
-return function()
- local Copy = require(script.Parent.copy)
-
- it("should return a copy of the given array", function()
- local array = { 1, 2, 3 }
-
- local new = Copy(array)
-
- expect(new).to.be.a("table")
- expect(new).never.to.equal(array)
-
- expect(new[1]).to.equal(1)
- expect(new[2]).to.equal(2)
- expect(new[3]).to.equal(3)
- end)
-
- it("should not copy nested arrays", function()
- local array = { 1, 2, { 3, 4 } }
-
- local new = Copy(array)
-
- expect(new).to.be.a("table")
- expect(new).never.to.equal(array)
-
- expect(new[1]).to.equal(1)
- expect(new[2]).to.equal(2)
- expect(new[3]).to.equal(array[3])
- end)
-end
diff --git a/src/Array/copyDeep.spec.lua b/src/Array/copyDeep.spec.lua
deleted file mode 100644
index 634c2ca..0000000
--- a/src/Array/copyDeep.spec.lua
+++ /dev/null
@@ -1,43 +0,0 @@
-return function()
- local CopyDeep = require(script.Parent.copyDeep)
-
- it("should return a copy of the given array", function()
- local array = { 1, 2, 3 }
-
- local new = CopyDeep(array)
-
- expect(new).to.be.a("table")
- expect(new).never.to.equal(array)
-
- expect(new[1]).to.equal(1)
- expect(new[2]).to.equal(2)
- expect(new[3]).to.equal(3)
- end)
-
- it("should copy nested arrays", function()
- local array = { 1, 2, { 3, 4 } }
-
- local new = CopyDeep(array)
-
- expect(new).to.be.a("table")
- expect(new).never.to.equal(array)
-
- expect(new[1]).to.equal(1)
- expect(new[2]).to.equal(2)
- expect(new[3]).never.to.equal(array[3])
- end)
-
- it("should copy metatables", function()
- local meta = setmetatable({}, { __index = function() end })
- local array = { { 1, 2, 3 }, { 4, 5, 6 }, meta }
-
- local new = CopyDeep(array)
-
- expect(new).to.be.a("table")
- expect(new).never.to.equal(array)
-
- expect(function()
- return getmetatable(new[3])
- end).to.be.a("function")
- end)
-end
diff --git a/src/Array/count.spec.lua b/src/Array/count.spec.lua
deleted file mode 100644
index a6cfedb..0000000
--- a/src/Array/count.spec.lua
+++ /dev/null
@@ -1,29 +0,0 @@
-return function()
- local Count = require(script.Parent.count)
-
- it("should return the number of elements in the given array", function()
- local array = { 1, 2, 3 }
-
- local count = Count(array)
-
- expect(count).to.equal(3)
- end)
-
- it("should return 0 for an empty array", function()
- local array = {}
-
- local count = Count(array)
-
- expect(count).to.equal(0)
- end)
-
- it("should return the number of elements matching the given predicate", function()
- local array = { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 }
-
- local count = Count(array, function(value)
- return value % 2 == 0
- end)
-
- expect(count).to.equal(5)
- end)
-end
diff --git a/src/Array/create.spec.lua b/src/Array/create.spec.lua
deleted file mode 100644
index aeab9fe..0000000
--- a/src/Array/create.spec.lua
+++ /dev/null
@@ -1,14 +0,0 @@
-return function()
- local Create = require(script.Parent.create)
-
- it("should return an array of the given length, filled with the given value", function()
- local array = Create(3, "Hello")
-
- expect(array).to.be.a("table")
- expect(#array).to.equal(3)
-
- expect(array[1]).to.equal("Hello")
- expect(array[2]).to.equal("Hello")
- expect(array[3]).to.equal("Hello")
- end)
-end
diff --git a/src/Array/difference.spec.lua b/src/Array/difference.spec.lua
deleted file mode 100644
index 5ae04ab..0000000
--- a/src/Array/difference.spec.lua
+++ /dev/null
@@ -1,40 +0,0 @@
-return function()
- local difference = require(script.Parent.difference)
-
- it("should return the difference between two arrays", function()
- local array = { "hello", "world" }
- local otherArray = { "cat", "dog", "hello" }
-
- local newArray = difference(array, otherArray)
-
- expect(newArray).to.be.a("table")
- expect(#newArray).to.equal(1)
-
- expect(table.find(newArray, "world")).to.be.ok()
- end)
-
- it("should accept vararg nil values", function()
- local array = { "hello", "world" }
- local otherArray = { "cat", "dog", "hello" }
-
- local newArray = difference(array, nil, otherArray)
-
- expect(newArray).to.be.a("table")
- expect(#newArray).to.equal(1)
-
- expect(table.find(newArray, "world")).to.be.ok()
- end)
-
- it("should accept multiple arrays", function()
- local array = { "hello", "world" }
- local otherArray = { "cat", "dog", "hello" }
- local anotherArray = { "hello", "panda" }
-
- local newArray = difference(array, otherArray, anotherArray)
-
- expect(newArray).to.be.a("table")
- expect(#newArray).to.equal(1)
-
- expect(table.find(newArray, "world")).to.be.ok()
- end)
-end
diff --git a/src/Array/differenceSymmetric.spec.lua b/src/Array/differenceSymmetric.spec.lua
deleted file mode 100644
index c3b03da..0000000
--- a/src/Array/differenceSymmetric.spec.lua
+++ /dev/null
@@ -1,47 +0,0 @@
-return function()
- local differenceSymmetric = require(script.Parent.differenceSymmetric)
-
- it("should return the symmetric difference between two arrays", function()
- local array = { "hello", "world" }
- local otherArray = { "cat", "dog", "hello" }
-
- local newArray = differenceSymmetric(array, otherArray)
-
- expect(newArray).to.be.a("table")
- expect(#newArray).to.equal(3)
-
- expect(table.find(newArray, "world")).to.be.ok()
- expect(table.find(newArray, "cat")).to.be.ok()
- expect(table.find(newArray, "dog")).to.be.ok()
- end)
-
- it("should accept vararg nil values", function()
- local array = { "hello", "world" }
- local otherArray = { "cat", "dog", "hello" }
-
- local newArray = differenceSymmetric(array, nil, otherArray)
-
- expect(newArray).to.be.a("table")
- expect(#newArray).to.equal(3)
-
- expect(table.find(newArray, "world")).to.be.ok()
- expect(table.find(newArray, "cat")).to.be.ok()
- expect(table.find(newArray, "dog")).to.be.ok()
- end)
-
- it("should accept multiple arrays", function()
- local array = { "hello", "world" }
- local otherArray = { "cat", "dog", "hello" }
- local anotherArray = { "hello", "panda" }
-
- local newArray = differenceSymmetric(array, otherArray, anotherArray)
-
- expect(newArray).to.be.a("table")
- expect(#newArray).to.equal(4)
-
- expect(table.find(newArray, "world")).to.be.ok()
- expect(table.find(newArray, "cat")).to.be.ok()
- expect(table.find(newArray, "dog")).to.be.ok()
- expect(table.find(newArray, "panda")).to.be.ok()
- end)
-end
diff --git a/src/Array/equals.spec.lua b/src/Array/equals.spec.lua
deleted file mode 100644
index cf461e2..0000000
--- a/src/Array/equals.spec.lua
+++ /dev/null
@@ -1,29 +0,0 @@
-return function()
- local Equals = require(script.Parent.equals)
-
- it("should return true if the arrays are equal", function()
- local array1 = { 1, 2, 3 }
- local array2 = { 1, 2, 3 }
-
- expect(Equals(array1, array2)).to.equal(true)
- end)
-
- it("should return false if the arrays are not equal", function()
- local array1 = { 1, 2, 3 }
- local array2 = { 1, 2, 4 }
-
- expect(Equals(array1, array2)).to.equal(false)
- end)
-
- it("should return false for nested arrays", function()
- --[[
- This is because the nested arrays have different memory addresses,
- despite having the same values. Use EqualsDeep instead if you want to
- compare nested arrays.
- --]]
- local array1 = { 1, 2, { 3, 4 } }
- local array2 = { 1, 2, { 3, 4 } }
-
- expect(Equals(array1, array2)).to.equal(false)
- end)
-end
diff --git a/src/Array/equalsDeep.spec.lua b/src/Array/equalsDeep.spec.lua
deleted file mode 100644
index 0cc546c..0000000
--- a/src/Array/equalsDeep.spec.lua
+++ /dev/null
@@ -1,24 +0,0 @@
-return function()
- local EqualsDeep = require(script.Parent.equalsDeep)
-
- it("should return true if the arrays are equal", function()
- local array1 = { 1, 2, 3 }
- local array2 = { 1, 2, 3 }
-
- expect(EqualsDeep(array1, array2)).to.equal(true)
- end)
-
- it("should return false if the arrays are not equal", function()
- local array1 = { 1, 2, 3 }
- local array2 = { 1, 2, 4 }
-
- expect(EqualsDeep(array1, array2)).to.equal(false)
- end)
-
- it("should return true if nested arrays are equal", function()
- local array1 = { 1, 2, { 3, 4 } }
- local array2 = { 1, 2, { 3, 4 } }
-
- expect(EqualsDeep(array1, array2)).to.equal(true)
- end)
-end
diff --git a/src/Array/every.spec.lua b/src/Array/every.spec.lua
deleted file mode 100644
index f627ee2..0000000
--- a/src/Array/every.spec.lua
+++ /dev/null
@@ -1,19 +0,0 @@
-return function()
- local Every = require(script.Parent.every)
-
- it("should return true if all elements match the predicate", function()
- local array = { 1, 2, 3 }
-
- expect(Every(array, function(value)
- return value % 1 == 0
- end)).to.equal(true)
- end)
-
- it("should return false if any elements do not match the predicate", function()
- local array = { 1, 2, 3 }
-
- expect(Every(array, function(value)
- return value % 2 == 0
- end)).to.equal(false)
- end)
-end
diff --git a/src/Array/filter.spec.lua b/src/Array/filter.spec.lua
deleted file mode 100644
index 865b1fe..0000000
--- a/src/Array/filter.spec.lua
+++ /dev/null
@@ -1,36 +0,0 @@
-return function()
- local Filter = require(script.Parent.filter)
-
- it(
- "should return a copy of the given array with only the elements that match the predicate",
- function()
- local array = { 1, 2, 3 }
-
- local new = Filter(array, function(value)
- return value % 2 == 0
- end)
-
- expect(new).to.be.a("table")
- expect(new).never.to.equal(array)
- expect(#new).to.equal(1)
-
- expect(new[1]).to.equal(2)
- end
- )
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3 }
-
- local new = Filter(array, function(value)
- return value % 2 == 0
- end)
-
- expect(new).never.to.equal(array)
-
- expect(array[1]).to.equal(1)
- expect(array[2]).to.equal(2)
- expect(array[3]).to.equal(3)
-
- expect(new[1]).to.equal(2)
- end)
-end
diff --git a/src/Array/find.spec.lua b/src/Array/find.spec.lua
deleted file mode 100644
index ddbd52b..0000000
--- a/src/Array/find.spec.lua
+++ /dev/null
@@ -1,33 +0,0 @@
-return function()
- local Find = require(script.Parent.find)
-
- it("should return the first element that matches the given value", function()
- local array = { 1, 2, 3 }
-
- expect(Find(array, 2)).to.equal(2)
- end)
-
- it("should return nil if no element matches the given value", function()
- local array = { 1, 2, 3 }
-
- expect(Find(array, 4)).never.to.be.ok()
- end)
-
- it("should return the first element that matches, given a starting index", function()
- local array = { 1, 2, 3 }
-
- expect(Find(array, 3, 2)).to.equal(3)
- end)
-
- it("should return nil if no element matches, given a starting index", function()
- local array = { 1, 2, 3 }
-
- expect(Find(array, 1, 2)).never.to.be.ok()
- end)
-
- it("should accept a negative starting index", function()
- local array = { 1, 2, 3 }
-
- expect(Find(array, 2, -1)).to.equal(2)
- end)
-end
diff --git a/src/Array/findLast.spec.lua b/src/Array/findLast.spec.lua
deleted file mode 100644
index b442310..0000000
--- a/src/Array/findLast.spec.lua
+++ /dev/null
@@ -1,33 +0,0 @@
-return function()
- local FindLast = require(script.Parent.findLast)
-
- it("should return the first element that matches the given value", function()
- local array = { 1, 2, 3 }
-
- expect(FindLast(array, 2)).to.equal(2)
- end)
-
- it("should return nil if no element matches the given value", function()
- local array = { 1, 2, 3 }
-
- expect(FindLast(array, 4)).never.to.be.ok()
- end)
-
- it("should return nil if no element matches, given a starting index", function()
- local array = { 1, 2, 3 }
-
- expect(FindLast(array, 3, 2)).never.to.be.ok()
- end)
-
- it("should return the first element that matches, given a starting index", function()
- local array = { 1, 2, 3 }
-
- expect(FindLast(array, 1, 2)).to.equal(1)
- end)
-
- it("should accept a negative starting index", function()
- local array = { 1, 2, 3 }
-
- expect(FindLast(array, 2, -1)).to.equal(2)
- end)
-end
diff --git a/src/Array/findWhere.spec.lua b/src/Array/findWhere.spec.lua
deleted file mode 100644
index a84aa23..0000000
--- a/src/Array/findWhere.spec.lua
+++ /dev/null
@@ -1,49 +0,0 @@
-return function()
- local FindWhere = require(script.Parent.findWhere)
-
- it("should return the first element in the array that matches the given predicate", function()
- local array = { 1, 2, 3 }
-
- local result = FindWhere(array, function(value)
- return value == 2
- end)
-
- expect(result).to.equal(2)
- end)
-
- it("should return nil if no element matches the given predicate", function()
- local array = { 1, 2, 3 }
-
- local result = FindWhere(array, function(value)
- return value == 4
- end)
-
- expect(result).never.to.be.ok()
- end)
-
- it(
- "should return the first element in the array that matches the given predicate, given a starting index",
- function()
- local array = { 1, 2, 3 }
-
- local result = FindWhere(array, function(value)
- return value == 3
- end, 2)
-
- expect(result).to.equal(3)
- end
- )
-
- it(
- "should return nil if no element matches the given predicate, given a starting index",
- function()
- local array = { 1, 2, 3 }
-
- local result = FindWhere(array, function(value)
- return value == 1
- end, 2)
-
- expect(result).never.to.be.ok()
- end
- )
-end
diff --git a/src/Array/findWhereLast.spec.lua b/src/Array/findWhereLast.spec.lua
deleted file mode 100644
index 8044325..0000000
--- a/src/Array/findWhereLast.spec.lua
+++ /dev/null
@@ -1,38 +0,0 @@
-return function()
- local FindWhereLast = require(script.Parent.findWhereLast)
-
- it("should return the last element that matches the predicate", function()
- local array = { 1, 2, 3, 4, 5 }
-
- expect(FindWhereLast(array, function(value)
- return value % 2 == 0
- end)).to.equal(4)
- end)
-
- it("should return nil if no element matches the predicate", function()
- local array = { 1, 2, 3, 4, 5 }
-
- expect(FindWhereLast(array, function(value)
- return value == 6
- end)).never.to.be.ok()
- end)
-
- it(
- "should return the last element that matches the predicate, given a starting index",
- function()
- local array = { 1, 2, 3, 4, 5 }
-
- expect(FindWhereLast(array, function(value)
- return value % 2 == 0
- end, 2)).to.equal(2)
- end
- )
-
- it("should return nil if no element matches the predicate, given a starting index", function()
- local array = { 1, 2, 3, 4, 5 }
-
- expect(FindWhereLast(array, function(value)
- return value == 4
- end, 3)).never.to.be.ok()
- end)
-end
diff --git a/src/Array/first.spec.lua b/src/Array/first.spec.lua
deleted file mode 100644
index 5264a5c..0000000
--- a/src/Array/first.spec.lua
+++ /dev/null
@@ -1,11 +0,0 @@
-return function()
- local First = require(script.Parent.first)
-
- it("should return the first element of the given array", function()
- local array = { 1, 2, 3 }
-
- local first = First(array)
-
- expect(first).to.equal(1)
- end)
-end
diff --git a/src/Array/flatten.spec.lua b/src/Array/flatten.spec.lua
deleted file mode 100644
index fe0747a..0000000
--- a/src/Array/flatten.spec.lua
+++ /dev/null
@@ -1,48 +0,0 @@
-return function()
- local Flatten = require(script.Parent.flatten)
-
- it("should return a flattened array", function()
- local array = { 1, 2, { 3, 4 } }
-
- local flattened = Flatten(array)
-
- expect(flattened).to.be.a("table")
- expect(#flattened).to.equal(4)
-
- expect(flattened[1]).to.equal(1)
- expect(flattened[2]).to.equal(2)
- expect(flattened[3]).to.equal(3)
- expect(flattened[4]).to.equal(4)
- end)
-
- it("should not flatten nested arrays if depth = 0", function()
- local array = { 1, 2, { 3, 4 } }
-
- local flattened = Flatten(array, 0)
-
- expect(flattened).to.be.a("table")
- expect(#flattened).to.equal(3)
-
- expect(flattened[1]).to.equal(1)
- expect(flattened[2]).to.equal(2)
- expect(flattened[3]).to.equal(array[3])
- end)
-
- it("should flatten as deeply as possible", function()
- local array = { 1, 2, { 3, 4, { 5, 6, { 7, 8 } } } }
-
- local flattened = Flatten(array)
-
- expect(flattened).to.be.a("table")
- expect(#flattened).to.equal(8)
-
- expect(flattened[1]).to.equal(1)
- expect(flattened[2]).to.equal(2)
- expect(flattened[3]).to.equal(3)
- expect(flattened[4]).to.equal(4)
- expect(flattened[5]).to.equal(5)
- expect(flattened[6]).to.equal(6)
- expect(flattened[7]).to.equal(7)
- expect(flattened[8]).to.equal(8)
- end)
-end
diff --git a/src/Array/freeze.spec.lua b/src/Array/freeze.spec.lua
deleted file mode 100644
index ea71549..0000000
--- a/src/Array/freeze.spec.lua
+++ /dev/null
@@ -1,48 +0,0 @@
-return function()
- local Freeze = require(script.Parent.freeze)
-
- it("should return a read-only copy of the given array", function()
- local array = { 1, 2, 3 }
-
- local frozen = Freeze(array)
-
- expect(frozen).to.be.a("table")
- expect(frozen).never.to.equal(array)
- expect(#frozen).to.equal(3)
-
- expect(frozen[1]).to.equal(1)
- expect(frozen[2]).to.equal(2)
- expect(frozen[3]).to.equal(3)
-
- expect(function()
- frozen[1] = 4
- end).to.throw()
- end)
-
- it("should not freeze nested arrays", function()
- local array = { 1, 2, { 3, 4 } }
-
- local frozen = Freeze(array)
-
- expect(frozen).to.be.a("table")
- expect(frozen).never.to.equal(array)
- expect(#frozen).to.equal(3)
-
- expect(frozen[1]).to.equal(1)
- expect(frozen[2]).to.equal(2)
- expect(frozen[3]).to.be.a("table")
- expect(frozen[3]).to.equal(array[3])
- expect(#frozen[3]).to.equal(2)
-
- expect(frozen[3][1]).to.equal(3)
- expect(frozen[3][2]).to.equal(4)
-
- expect(function()
- frozen[1] = 4
- end).to.throw()
-
- expect(function()
- frozen[3][1] = 5
- end).never.to.throw()
- end)
-end
diff --git a/src/Array/freezeDeep.spec.lua b/src/Array/freezeDeep.spec.lua
deleted file mode 100644
index 407c0cb..0000000
--- a/src/Array/freezeDeep.spec.lua
+++ /dev/null
@@ -1,48 +0,0 @@
-return function()
- local FreezeDeep = require(script.Parent.freezeDeep)
-
- it("should return a read-only copy of the given array", function()
- local array = { 1, 2, 3 }
-
- local frozen = FreezeDeep(array)
-
- expect(frozen).to.be.a("table")
- expect(frozen).never.to.equal(array)
- expect(#frozen).to.equal(3)
-
- expect(frozen[1]).to.equal(1)
- expect(frozen[2]).to.equal(2)
- expect(frozen[3]).to.equal(3)
-
- expect(function()
- frozen[1] = 4
- end).to.throw()
- end)
-
- it("should return a read-only copy of nested arrays", function()
- local array = { 1, 2, { 3, 4 } }
-
- local frozen = FreezeDeep(array)
-
- expect(frozen).to.be.a("table")
- expect(frozen).never.to.equal(array)
- expect(#frozen).to.equal(3)
-
- expect(frozen[1]).to.equal(1)
- expect(frozen[2]).to.equal(2)
- expect(frozen[3]).to.be.a("table")
- expect(frozen[3]).never.to.equal(array[3])
- expect(#frozen[3]).to.equal(2)
-
- expect(frozen[3][1]).to.equal(3)
- expect(frozen[3][2]).to.equal(4)
-
- expect(function()
- frozen[1] = 4
- end).to.throw()
-
- expect(function()
- frozen[3][1] = 5
- end).to.throw()
- end)
-end
diff --git a/src/Array/includes.spec.lua b/src/Array/includes.spec.lua
deleted file mode 100644
index b2655b5..0000000
--- a/src/Array/includes.spec.lua
+++ /dev/null
@@ -1,11 +0,0 @@
-return function()
- local Includes = require(script.Parent.includes)
-
- it("should return true if the given array includes the given value", function()
- local array = { 1, 2, 3 }
-
- local includes = Includes(array, 2)
-
- expect(includes).to.equal(true)
- end)
-end
diff --git a/src/Array/insert.spec.lua b/src/Array/insert.spec.lua
deleted file mode 100644
index 9ed0224..0000000
--- a/src/Array/insert.spec.lua
+++ /dev/null
@@ -1,57 +0,0 @@
-return function()
- local Insert = require(script.Parent.insert)
-
- it(
- "should insert the given values into an array at the given index, shifting all values after it to the right",
- function()
- local array = { 1, 2, 3 }
-
- local newArray = Insert(array, 2, 4, 5) -- { 1, 4, 5, 2, 3 }
-
- expect(newArray).to.be.a("table")
- expect(#newArray).to.equal(5)
-
- expect(newArray[1]).to.equal(1)
- expect(newArray[2]).to.equal(4)
- expect(newArray[3]).to.equal(5)
- expect(newArray[4]).to.equal(2)
- expect(newArray[5]).to.equal(3)
- end
- )
-
- it("should accept negative indices", function()
- local array = { 1, 2, 3 }
-
- local newArray = Insert(array, 0, 4, 5) -- { 1, 2, 3, 4, 5 }
- local newArray2 = Insert(array, -1, 4, 5) -- { 1, 2, 4, 5, 3 }
-
- expect(newArray).to.be.a("table")
- expect(#newArray).to.equal(5)
- expect(newArray[5]).to.equal(5)
-
- expect(newArray2).to.be.a("table")
- expect(#newArray2).to.equal(5)
- expect(newArray2[3]).to.equal(4)
- expect(newArray2[5]).to.equal(3)
- end)
-
- it("should accept length+1", function()
- local array = { 1, 2, 3 }
-
- local newArray = Insert(array, 4, 4, 5) -- { 1, 2, 3, 4, 5 }
- local newArray2 = Insert(array, 5, 4) -- { 1, 2, 3 }
- local newArray3 = Insert(array, 0, 4) -- { 1, 2, 3, 4 }
-
- expect(newArray).to.be.a("table")
- expect(#newArray).to.equal(5)
- expect(newArray[5]).to.equal(5)
-
- expect(newArray2).to.be.a("table")
- expect(#newArray2).to.equal(3)
- expect(newArray2[3]).to.equal(3)
-
- expect(newArray3).to.be.a("table")
- expect(#newArray3).to.equal(4)
- expect(newArray3[4]).to.equal(4)
- end)
-end
diff --git a/src/Array/is.spec.lua b/src/Array/is.spec.lua
deleted file mode 100644
index a5b1603..0000000
--- a/src/Array/is.spec.lua
+++ /dev/null
@@ -1,11 +0,0 @@
-return function()
- local isArray = require(script.Parent.is)
-
- it("should return whether the given object is an array", function()
- expect(isArray({})).to.equal(false)
- expect(isArray({ 1, 2, 3 })).to.equal(true)
- expect(isArray({ hello = "world" })).to.equal(false)
- expect(isArray({ 1, 2, hello = "world" })).to.equal(false)
- expect(isArray({ 1, 2, 3, nil, 5 })).to.equal(true)
- end)
-end
diff --git a/src/Array/last.spec.lua b/src/Array/last.spec.lua
deleted file mode 100644
index d205704..0000000
--- a/src/Array/last.spec.lua
+++ /dev/null
@@ -1,11 +0,0 @@
-return function()
- local Last = require(script.Parent.last)
-
- it("should return the last element of the given array", function()
- local array = { 1, 2, 3 }
-
- local last = Last(array)
-
- expect(last).to.equal(3)
- end)
-end
diff --git a/src/Array/map.spec.lua b/src/Array/map.spec.lua
deleted file mode 100644
index fd4fbee..0000000
--- a/src/Array/map.spec.lua
+++ /dev/null
@@ -1,31 +0,0 @@
-return function()
- local Map = require(script.Parent.map)
-
- it("should return an array where values are the result of the mapper function", function()
- local array = Map({ 1, 2, 3 }, function(value)
- return value * 2
- end)
-
- expect(array).to.be.a("table")
- expect(#array).to.equal(3)
-
- expect(array[1]).to.equal(2)
- expect(array[2]).to.equal(4)
- expect(array[3]).to.equal(6)
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3 }
-
- Map(array, function(value)
- return value * 2
- end)
-
- expect(array).to.be.a("table")
- expect(#array).to.equal(3)
-
- expect(array[1]).to.equal(1)
- expect(array[2]).to.equal(2)
- expect(array[3]).to.equal(3)
- end)
-end
diff --git a/src/Array/pop.spec.lua b/src/Array/pop.spec.lua
deleted file mode 100644
index 1f19e99..0000000
--- a/src/Array/pop.spec.lua
+++ /dev/null
@@ -1,32 +0,0 @@
-return function()
- local Pop = require(script.Parent.pop)
-
- it("should remove the last element of the given array", function()
- local array = { 1, 2, 3 }
-
- local popped = Pop(array)
-
- expect(popped[1]).to.equal(1)
- expect(popped[2]).to.equal(2)
- expect(popped[3]).never.to.be.ok()
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3 }
-
- Pop(array)
-
- expect(array[3]).to.equal(3)
- end)
-
- it("should pop multiple elements from the array", function()
- local array = { 1, 2, 3, 4, 5 }
-
- local popped = Pop(array, 2)
-
- expect(popped[1]).to.equal(1)
- expect(popped[2]).to.equal(2)
- expect(popped[3]).to.equal(3)
- expect(popped[4]).never.to.be.ok()
- end)
-end
diff --git a/src/Array/push.spec.lua b/src/Array/push.spec.lua
deleted file mode 100644
index a4cff8c..0000000
--- a/src/Array/push.spec.lua
+++ /dev/null
@@ -1,29 +0,0 @@
-return function()
- local Push = require(script.Parent.push)
-
- it("should return an array with new value(s) added", function()
- local array = Push({ 1, 2, 3 }, "Hello")
-
- expect(array).to.be.a("table")
- expect(#array).to.equal(4)
-
- expect(array[1]).to.equal(1)
- expect(array[2]).to.equal(2)
- expect(array[3]).to.equal(3)
- expect(array[4]).to.equal("Hello")
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3 }
-
- Push(array, "Hello")
-
- expect(array).to.be.a("table")
- expect(#array).to.equal(3)
-
- expect(array[1]).to.equal(1)
- expect(array[2]).to.equal(2)
- expect(array[3]).to.equal(3)
- expect(array[4]).never.to.be.ok()
- end)
-end
diff --git a/src/Array/reduce.spec.lua b/src/Array/reduce.spec.lua
deleted file mode 100644
index 68cf1f9..0000000
--- a/src/Array/reduce.spec.lua
+++ /dev/null
@@ -1,36 +0,0 @@
-return function()
- local Reduce = require(script.Parent.reduce)
-
- it("should reduce the given array to a single value", function()
- local array = { 1, 2, 3 }
-
- local reduced = Reduce(array, function(accumulator, value)
- return accumulator + value
- end, 0)
-
- expect(reduced).to.equal(6)
- end)
-
- it(
- "should reduce the given array to a single value, using the first element as the initial value",
- function()
- local array = { 1, 2, 3 }
-
- local reduced = Reduce(array, function(accumulator, value)
- return accumulator - value
- end)
-
- expect(reduced).to.equal(-4)
- end
- )
-
- it("should reduce the array, even if the array has a falsy initial value", function()
- local array = { true, false, false }
-
- local reduced = Reduce(array, function(accumulator, value)
- return accumulator or value
- end, false)
-
- expect(reduced).to.equal(true)
- end)
-end
diff --git a/src/Array/reduceRight.spec.lua b/src/Array/reduceRight.spec.lua
deleted file mode 100644
index d6b41cc..0000000
--- a/src/Array/reduceRight.spec.lua
+++ /dev/null
@@ -1,39 +0,0 @@
-return function()
- local ReduceRight = require(script.Parent.reduceRight)
-
- it("should reduce the given array from the right", function()
- local array = { 1, 2, 3 }
-
- local reduced = ReduceRight(array, function(accumulator, value)
- return accumulator + value
- end, 0)
-
- expect(reduced).to.equal(6)
- end)
-
- it(
- "should reduce the given array from the right, using the last element as the initial value",
- function()
- local array = { 1, 2, 3 }
-
- local reduced = ReduceRight(array, function(accumulator, value)
- return accumulator - value
- end)
-
- expect(reduced).to.equal(0)
- end
- )
-
- it(
- "should reduce the array from the right, even if the array has a falsy initial value",
- function()
- local array = { true, false, true }
-
- local reduced = ReduceRight(array, function(accumulator, value)
- return accumulator or value
- end, false)
-
- expect(reduced).to.equal(true)
- end
- )
-end
diff --git a/src/Array/removeIndex.spec.lua b/src/Array/removeIndex.spec.lua
deleted file mode 100644
index 2a44338..0000000
--- a/src/Array/removeIndex.spec.lua
+++ /dev/null
@@ -1,31 +0,0 @@
-return function()
- local RemoveIndex = require(script.Parent.removeIndex)
-
- it("should remove the element at the given index", function()
- local array = { 1, 2, 3 }
-
- local removed = RemoveIndex(array, 2)
-
- expect(removed[1]).to.equal(1)
- expect(removed[2]).to.equal(3)
- expect(removed[3]).never.to.be.ok()
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3 }
-
- RemoveIndex(array, 2)
-
- expect(array[2]).to.equal(2)
- end)
-
- it("should remove an element at the given negative index", function()
- local array = { 1, 2, 3 }
-
- local removed = RemoveIndex(array, -1)
-
- expect(removed[1]).to.equal(1)
- expect(removed[2]).to.equal(3)
- expect(removed[3]).never.to.be.ok()
- end)
-end
diff --git a/src/Array/removeIndices.spec.lua b/src/Array/removeIndices.spec.lua
deleted file mode 100644
index 64dceba..0000000
--- a/src/Array/removeIndices.spec.lua
+++ /dev/null
@@ -1,33 +0,0 @@
-return function()
- local RemoveIndices = require(script.Parent.removeIndices)
-
- it("should remove the elements at the given indices", function()
- local array = { 1, 2, 3, 4, 5 }
-
- local removed = RemoveIndices(array, 2, 4)
-
- expect(removed[1]).to.equal(1)
- expect(removed[2]).to.equal(3)
- expect(removed[3]).to.equal(5)
- expect(removed[4]).never.to.be.ok()
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3, 4, 5 }
-
- RemoveIndices(array, 2, 4)
-
- expect(array[4]).to.equal(4)
- end)
-
- it("should remove indices at given negative indices", function()
- local array = { 1, 2, 3, 4, 5 }
-
- local removed = RemoveIndices(array, -1, -3)
-
- expect(removed[1]).to.equal(1)
- expect(removed[2]).to.equal(3)
- expect(removed[3]).to.equal(5)
- expect(removed[4]).never.to.be.ok()
- end)
-end
diff --git a/src/Array/removeValue.spec.lua b/src/Array/removeValue.spec.lua
deleted file mode 100644
index 2c8c172..0000000
--- a/src/Array/removeValue.spec.lua
+++ /dev/null
@@ -1,23 +0,0 @@
-return function()
- local RemoveValue = require(script.Parent.removeValue)
-
- it("should remove the elements with the given value", function()
- local array = { 1, 2, 3, 4, 5 }
-
- local removed = RemoveValue(array, 2)
-
- expect(removed[1]).to.equal(1)
- expect(removed[2]).to.equal(3)
- expect(removed[3]).to.equal(4)
- expect(removed[4]).to.equal(5)
- expect(removed[5]).never.to.be.ok()
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3, 4, 5 }
-
- RemoveValue(array, 2)
-
- expect(array[2]).to.equal(2)
- end)
-end
diff --git a/src/Array/removeValues.spec.lua b/src/Array/removeValues.spec.lua
deleted file mode 100644
index ffd7313..0000000
--- a/src/Array/removeValues.spec.lua
+++ /dev/null
@@ -1,22 +0,0 @@
-return function()
- local RemoveValues = require(script.Parent.removeValues)
-
- it("should remove the elements with the given values", function()
- local array = { 1, 2, 3, 4, 5 }
-
- local removed = RemoveValues(array, 2, 4)
-
- expect(removed[1]).to.equal(1)
- expect(removed[2]).to.equal(3)
- expect(removed[3]).to.equal(5)
- expect(removed[4]).never.to.be.ok()
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3, 4, 5 }
-
- RemoveValues(array, 2, 4)
-
- expect(array[4]).to.equal(4)
- end)
-end
diff --git a/src/Array/reverse.spec.lua b/src/Array/reverse.spec.lua
deleted file mode 100644
index 6b00930..0000000
--- a/src/Array/reverse.spec.lua
+++ /dev/null
@@ -1,23 +0,0 @@
-return function()
- local Reverse = require(script.Parent.reverse)
-
- it("should reverse the given array", function()
- local array = { 1, 2, 3 }
-
- local reversed = Reverse(array)
-
- expect(reversed[1]).to.equal(3)
- expect(reversed[2]).to.equal(2)
- expect(reversed[3]).to.equal(1)
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3 }
-
- Reverse(array)
-
- expect(array[1]).to.equal(1)
- expect(array[2]).to.equal(2)
- expect(array[3]).to.equal(3)
- end)
-end
diff --git a/src/Array/set.spec.lua b/src/Array/set.spec.lua
deleted file mode 100644
index 202eda2..0000000
--- a/src/Array/set.spec.lua
+++ /dev/null
@@ -1,21 +0,0 @@
-return function()
- local Set = require(script.Parent.set)
-
- it("should set the given value in the given array", function()
- local array = { 1, 2, 3 }
-
- local new = Set(array, 2, 4)
-
- expect(new[2]).to.equal(4)
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3 }
-
- Set(array, 2, 4)
-
- expect(array[1]).to.equal(1)
- expect(array[2]).to.equal(2)
- expect(array[3]).to.equal(3)
- end)
-end
diff --git a/src/Array/shift.spec.lua b/src/Array/shift.spec.lua
deleted file mode 100644
index 4639d56..0000000
--- a/src/Array/shift.spec.lua
+++ /dev/null
@@ -1,32 +0,0 @@
-return function()
- local Shift = require(script.Parent.shift)
-
- it("should remove the first item from the array", function()
- local array = { 1, 2, 3 }
-
- local shifted = Shift(array)
-
- expect(shifted[1]).to.equal(2)
- expect(shifted[2]).to.equal(3)
- expect(shifted[3]).never.to.be.ok()
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3 }
-
- Shift(array)
-
- expect(array[1]).to.equal(1)
- end)
-
- it("should shift given a number of items to remove", function()
- local array = { 1, 2, 3, 4, 5 }
-
- local shifted = Shift(array, 2)
-
- expect(shifted[1]).to.equal(3)
- expect(shifted[2]).to.equal(4)
- expect(shifted[3]).to.equal(5)
- expect(shifted[4]).never.to.be.ok()
- end)
-end
diff --git a/src/Array/shuffle.spec.lua b/src/Array/shuffle.spec.lua
deleted file mode 100644
index e49628c..0000000
--- a/src/Array/shuffle.spec.lua
+++ /dev/null
@@ -1,13 +0,0 @@
-return function()
- local Shuffle = require(script.Parent.shuffle)
-
- it("should return a shuffled array", function()
- local array = { 1, 2, 3 }
-
- local shuffled = Shuffle(array)
-
- expect(shuffled).to.be.a("table")
- expect(#shuffled).to.equal(3)
- expect(shuffled).never.to.equal(array)
- end)
-end
diff --git a/src/Array/slice.spec.lua b/src/Array/slice.spec.lua
deleted file mode 100644
index 048097f..0000000
--- a/src/Array/slice.spec.lua
+++ /dev/null
@@ -1,47 +0,0 @@
-return function()
- local Slice = require(script.Parent.slice)
-
- it("should return a slice of the given array", function()
- local array = { 1, 2, 3 }
-
- local slice = Slice(array, 2, 3)
-
- expect(slice).to.be.a("table")
- expect(#slice).to.equal(2)
- expect(slice[1]).to.equal(2)
- expect(slice[2]).to.equal(3)
- end)
-
- it("should return a slice of the given array with a negative start index", function()
- local array = { 1, 2, 3 }
-
- local slice = Slice(array, -1, 3)
-
- expect(slice).to.be.a("table")
- expect(#slice).to.equal(2)
- expect(slice[1]).to.equal(2)
- expect(slice[2]).to.equal(3)
- end)
-
- it("should return a slice of the given array with a negative end index", function()
- local array = { 1, 2, 3 }
-
- local slice = Slice(array, 1, -1)
-
- expect(slice).to.be.a("table")
- expect(#slice).to.equal(2)
- expect(slice[1]).to.equal(1)
- expect(slice[2]).to.equal(2)
- end)
-
- it("should return a slice of the given array with a negative start and end index", function()
- local array = { 1, 2, 3 }
-
- local slice = Slice(array, -2, -1)
-
- expect(slice).to.be.a("table")
- expect(#slice).to.equal(2)
- expect(slice[1]).to.equal(1)
- expect(slice[2]).to.equal(2)
- end)
-end
diff --git a/src/Array/some.spec.lua b/src/Array/some.spec.lua
deleted file mode 100644
index 998aa9b..0000000
--- a/src/Array/some.spec.lua
+++ /dev/null
@@ -1,23 +0,0 @@
-return function()
- local Some = require(script.Parent.some)
-
- it("should return true if the given predicate returns true for any element", function()
- local array = { 1, 2, 3 }
-
- local result = Some(array, function(value)
- return value == 2
- end)
-
- expect(result).to.equal(true)
- end)
-
- it("should return false if the given predicate returns false for all elements", function()
- local array = { 1, 2, 3 }
-
- local result = Some(array, function(value)
- return value == 4
- end)
-
- expect(result).to.equal(false)
- end)
-end
diff --git a/src/Array/sort.spec.lua b/src/Array/sort.spec.lua
deleted file mode 100644
index fe3270b..0000000
--- a/src/Array/sort.spec.lua
+++ /dev/null
@@ -1,44 +0,0 @@
-return function()
- local Sort = require(script.Parent.sort)
-
- it("should sort the given array", function()
- local array = { 1, 2, 3 }
-
- local new = Sort(array, function(a, b)
- return a < b
- end)
-
- expect(new).to.be.a("table")
- expect(#new).to.equal(3)
- expect(new[1]).to.equal(1)
- expect(new[2]).to.equal(2)
- expect(new[3]).to.equal(3)
- end)
-
- it("should sort the given array with a custom compare function", function()
- local array = { 1, 2, 3 }
-
- local new = Sort(array, function(a, b)
- return a > b
- end)
-
- expect(new).to.be.a("table")
- expect(#new).to.equal(3)
- expect(new[1]).to.equal(3)
- expect(new[2]).to.equal(2)
- expect(new[3]).to.equal(1)
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3 }
-
- Sort(array, function(a, b)
- return a > b
- end)
-
- expect(array).to.be.a("table")
- expect(array[1]).to.equal(1)
- expect(array[2]).to.equal(2)
- expect(array[3]).to.equal(3)
- end)
-end
diff --git a/src/Array/splice.spec.lua b/src/Array/splice.spec.lua
deleted file mode 100644
index 8a5b16b..0000000
--- a/src/Array/splice.spec.lua
+++ /dev/null
@@ -1,27 +0,0 @@
-return function()
- local Splice = require(script.Parent.splice)
-
- it("should insert the given values into the given array", function()
- local array = { 1, 2, 3 }
-
- local spliced = Splice(array, 2, 0, 4, 5)
-
- expect(spliced).to.be.a("table")
- expect(#spliced).to.equal(3)
- expect(spliced[1]).to.equal(1)
- expect(spliced[2]).to.equal(4)
- expect(spliced[3]).to.equal(5)
- end)
-
- it("should insert the given values into the given array with a negative index", function()
- local array = { 1, 2, 3 }
-
- local spliced = Splice(array, -2, 0, 4, 5)
-
- expect(spliced).to.be.a("table")
- expect(#spliced).to.equal(2)
- expect(spliced[1]).to.equal(4)
- expect(spliced[2]).to.equal(5)
- expect(spliced[3]).never.to.be.ok()
- end)
-end
diff --git a/src/Array/toSet.spec.lua b/src/Array/toSet.spec.lua
deleted file mode 100644
index 21b94fc..0000000
--- a/src/Array/toSet.spec.lua
+++ /dev/null
@@ -1,38 +0,0 @@
-return function()
- local ToSet = require(script.Parent.toSet)
-
- it("should return a set", function()
- local array = { 1, 2, 3 }
-
- local set = ToSet(array)
-
- expect(set).to.be.a("table")
- expect(set[1]).to.equal(true)
- expect(set[2]).to.equal(true)
- expect(set[3]).to.equal(true)
- end)
-
- it("should return a set of strings", function()
- local array = { "a", "b", "b", "c" }
-
- local set = ToSet(array)
-
- expect(set).to.be.a("table")
- expect(set["a"]).to.equal(true)
- expect(set["b"]).to.equal(true)
- expect(set["c"]).to.equal(true)
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3 }
-
- ToSet(array)
-
- expect(array).to.be.a("table")
- expect(#array).to.equal(3)
-
- expect(array[1]).to.equal(1)
- expect(array[2]).to.equal(2)
- expect(array[3]).to.equal(3)
- end)
-end
diff --git a/src/Array/unshift.spec.lua b/src/Array/unshift.spec.lua
deleted file mode 100644
index 2a1c267..0000000
--- a/src/Array/unshift.spec.lua
+++ /dev/null
@@ -1,41 +0,0 @@
-return function()
- local Unshift = require(script.Parent.unshift)
-
- it("should return a new array with the given value at the beginning", function()
- local array = { 1, 2, 3 }
-
- local newArray = Unshift(array, 4)
-
- expect(newArray).to.be.a("table")
- expect(#newArray).to.equal(4)
-
- expect(newArray[1]).to.equal(4)
- expect(newArray[2]).to.equal(1)
- expect(newArray[3]).to.equal(2)
- expect(newArray[4]).to.equal(3)
- end)
-
- it("should prepend multiple values to the array", function()
- local array = { 1, 2, 3 }
-
- local newArray = Unshift(array, 4, 5, 6)
-
- expect(newArray).to.be.a("table")
- expect(#newArray).to.equal(6)
-
- expect(newArray[1]).to.equal(4)
- expect(newArray[2]).to.equal(5)
- expect(newArray[3]).to.equal(6)
- expect(newArray[4]).to.equal(1)
- expect(newArray[5]).to.equal(2)
- expect(newArray[6]).to.equal(3)
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3 }
-
- Unshift(array, 4)
-
- expect(array[1]).to.equal(1)
- end)
-end
diff --git a/src/Array/update.spec.lua b/src/Array/update.spec.lua
deleted file mode 100644
index aca907f..0000000
--- a/src/Array/update.spec.lua
+++ /dev/null
@@ -1,48 +0,0 @@
-return function()
- local Update = require(script.Parent.update)
-
- it("should update the value at the given index", function()
- local array = { 1, 2, 3 }
-
- local result = Update(array, 2, function(value)
- return value + 1
- end)
-
- expect(result).to.be.a("table")
- expect(#result).to.equal(3)
-
- expect(result[1]).to.equal(1)
- expect(result[2]).to.equal(3)
- expect(result[3]).to.equal(3)
- end)
-
- it("should create values using the callback", function()
- local array = { 1, 2, 3 }
-
- local result = Update(array, 4, function(value)
- return value + 1
- end, function()
- return 5
- end)
-
- expect(result).to.be.a("table")
- expect(#result).to.equal(4)
-
- expect(result[1]).to.equal(1)
- expect(result[2]).to.equal(2)
- expect(result[3]).to.equal(3)
- expect(result[4]).to.equal(5)
- end)
-
- it("should not modify the original array", function()
- local array = { 1, 2, 3 }
-
- Update(array, 2, function(value)
- return value + 1
- end)
-
- expect(array[1]).to.equal(1)
- expect(array[2]).to.equal(2)
- expect(array[3]).to.equal(3)
- end)
-end
diff --git a/src/Array/zip.spec.lua b/src/Array/zip.spec.lua
deleted file mode 100644
index a6920e4..0000000
--- a/src/Array/zip.spec.lua
+++ /dev/null
@@ -1,46 +0,0 @@
-return function()
- local Zip = require(script.Parent.zip)
-
- it("should zip together two arrays", function()
- local array1 = { 1, 2, 3 }
- local array2 = { "a", "b", "c" }
-
- local new = Zip(array1, array2)
-
- expect(new).to.be.a("table")
- expect(#new).to.equal(3)
-
- expect(new[1]).to.be.a("table")
- expect(new[1][1]).to.equal(1)
- expect(new[1][2]).to.equal("a")
-
- expect(new[2]).to.be.a("table")
- expect(new[2][1]).to.equal(2)
- expect(new[2][2]).to.equal("b")
-
- expect(new[3]).to.be.a("table")
- expect(new[3][1]).to.equal(3)
- expect(new[3][2]).to.equal("c")
- end)
-
- it("should not modify the original arrays", function()
- local array1 = { 1, 2, 3 }
- local array2 = { "a", "b", "c" }
-
- Zip(array1, array2)
-
- expect(array1).to.be.a("table")
- expect(#array1).to.equal(3)
-
- expect(array1[1]).to.equal(1)
- expect(array1[2]).to.equal(2)
- expect(array1[3]).to.equal(3)
-
- expect(array2).to.be.a("table")
- expect(#array2).to.equal(3)
-
- expect(array2[1]).to.equal("a")
- expect(array2[2]).to.equal("b")
- expect(array2[3]).to.equal("c")
- end)
-end
diff --git a/src/Array/zipAll.spec.lua b/src/Array/zipAll.spec.lua
deleted file mode 100644
index 7c23d6c..0000000
--- a/src/Array/zipAll.spec.lua
+++ /dev/null
@@ -1,69 +0,0 @@
-return function()
- local None = require(script.Parent.Parent.None)
- local ZipAll = require(script.Parent.zipAll)
-
- it("should zip together two arrays", function()
- local array1 = { 1, 2, 3 }
- local array2 = { "a", "b", "c" }
-
- local new = ZipAll(array1, array2)
-
- expect(new).to.be.a("table")
- expect(#new).to.equal(3)
-
- expect(new[1]).to.be.a("table")
- expect(new[1][1]).to.equal(1)
- expect(new[1][2]).to.equal("a")
-
- expect(new[2]).to.be.a("table")
- expect(new[2][1]).to.equal(2)
- expect(new[2][2]).to.equal("b")
-
- expect(new[3]).to.be.a("table")
- expect(new[3][1]).to.equal(3)
- expect(new[3][2]).to.equal("c")
- end)
-
- it("should not modify the original arrays", function()
- local array1 = { 1, 2, 3 }
- local array2 = { "a", "b", "c" }
-
- ZipAll(array1, array2)
-
- expect(array1).to.be.a("table")
- expect(#array1).to.equal(3)
-
- expect(array1[1]).to.equal(1)
- expect(array1[2]).to.equal(2)
- expect(array1[3]).to.equal(3)
-
- expect(array2).to.be.a("table")
- expect(#array2).to.equal(3)
-
- expect(array2[1]).to.equal("a")
- expect(array2[2]).to.equal("b")
- expect(array2[3]).to.equal("c")
- end)
-
- it("should fill in the blanks with None", function()
- local array1 = { 1, 2, 3 }
- local array2 = { "a", "b" }
-
- local new = ZipAll(array1, array2)
-
- expect(new).to.be.a("table")
- expect(#new).to.equal(3)
-
- expect(new[1]).to.be.a("table")
- expect(new[1][1]).to.equal(1)
- expect(new[1][2]).to.equal("a")
-
- expect(new[2]).to.be.a("table")
- expect(new[2][1]).to.equal(2)
- expect(new[2][2]).to.equal("b")
-
- expect(new[3]).to.be.a("table")
- expect(new[3][1]).to.equal(3)
- expect(new[3][2]).to.equal(None)
- end)
-end
diff --git a/src/Dictionary/copy.spec.lua b/src/Dictionary/copy.spec.lua
deleted file mode 100644
index 73f5397..0000000
--- a/src/Dictionary/copy.spec.lua
+++ /dev/null
@@ -1,25 +0,0 @@
-return function()
- local Copy = require(script.Parent.copy)
-
- it("should return a copy of the given dictionary", function()
- local dictionary = { hello = "world" }
-
- local new = Copy(dictionary)
-
- expect(new).to.be.a("table")
- expect(new).never.to.equal(dictionary)
-
- expect(new.hello).to.equal("world")
- end)
-
- it("should not copy nested dictionaries", function()
- local dictionary = { hello = { world = "goodbye" } }
-
- local new = Copy(dictionary)
-
- expect(new).to.be.a("table")
- expect(new).never.to.equal(dictionary)
-
- expect(new.hello).to.equal(dictionary.hello)
- end)
-end
diff --git a/src/Dictionary/copyDeep.spec.lua b/src/Dictionary/copyDeep.spec.lua
deleted file mode 100644
index 324d2df..0000000
--- a/src/Dictionary/copyDeep.spec.lua
+++ /dev/null
@@ -1,52 +0,0 @@
-return function()
- local CopyDeep = require(script.Parent.copyDeep)
-
- it("should return a copy of the given dictionary", function()
- local dictionary = {
- hello = "world",
- }
-
- local new = CopyDeep(dictionary)
-
- expect(new).to.be.a("table")
- expect(new).never.to.equal(dictionary)
-
- expect(new.hello).to.equal("world")
- end)
-
- it("should copy nested dictionaries", function()
- local dictionary = {
- hello = {
- world = "goodbye",
- },
- }
-
- local new = CopyDeep(dictionary)
-
- expect(new).to.be.a("table")
- expect(new).never.to.equal(dictionary)
-
- expect(new.hello).to.be.a("table")
- expect(new.hello).never.to.equal(dictionary.hello)
-
- expect(new.hello.world).to.equal("goodbye")
- end)
-
- it("should copy metatables", function()
- local meta = setmetatable({}, { __index = function() end })
- local dictionary = {
- hello = {},
- world = {},
- meta = meta,
- }
-
- local new = CopyDeep(dictionary)
-
- expect(new).to.be.a("table")
- expect(new).never.to.equal(dictionary)
-
- expect(function()
- return getmetatable(new[3])
- end).to.be.a("function")
- end)
-end
diff --git a/src/Dictionary/count.spec.lua b/src/Dictionary/count.spec.lua
deleted file mode 100644
index c4a0582..0000000
--- a/src/Dictionary/count.spec.lua
+++ /dev/null
@@ -1,29 +0,0 @@
-return function()
- local Count = require(script.Parent.count)
-
- it("should return the number of elements in the given dictionary", function()
- local dictionary = { hello = "world", goodbye = "world" }
-
- local count = Count(dictionary)
-
- expect(count).to.equal(2)
- end)
-
- it("should return 0 for an empty dictionary", function()
- local dictionary = {}
-
- local count = Count(dictionary)
-
- expect(count).to.equal(0)
- end)
-
- it("should return the number of elements matching the given predicate", function()
- local dictionary = { hello = "world", goodbye = "world" }
-
- local count = Count(dictionary, function(_, key)
- return key == "goodbye"
- end)
-
- expect(count).to.equal(1)
- end)
-end
diff --git a/src/Dictionary/entries.spec.lua b/src/Dictionary/entries.spec.lua
deleted file mode 100644
index 4d2cb8d..0000000
--- a/src/Dictionary/entries.spec.lua
+++ /dev/null
@@ -1,22 +0,0 @@
-return function()
- local Entries = require(script.Parent.entries)
-
- it("should return a list of entries as key-value pairs", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local entries = Entries(dictionary)
-
- expect(entries).to.be.a("table")
- expect(#entries).to.equal(2)
-
- expect(entries[1]).to.be.a("table")
- expect(#entries[1]).to.equal(2)
- expect(entries[1][1]).to.equal("hello")
- expect(entries[1][2]).to.equal("roblox")
-
- expect(entries[2]).to.be.a("table")
- expect(#entries[2]).to.equal(2)
- expect(entries[2][1]).to.equal("goodbye")
- expect(entries[2][2]).to.equal("world")
- end)
-end
diff --git a/src/Dictionary/equals.spec.lua b/src/Dictionary/equals.spec.lua
deleted file mode 100644
index 57a55ea..0000000
--- a/src/Dictionary/equals.spec.lua
+++ /dev/null
@@ -1,29 +0,0 @@
-return function()
- local Equals = require(script.Parent.equals)
-
- it("should return true if the dictionaries are equal", function()
- local dictionary1 = { hello = "world", goodbye = "world" }
- local dictionary2 = { hello = "world", goodbye = "world" }
-
- expect(Equals(dictionary1, dictionary2)).to.equal(true)
- end)
-
- it("should return false if the dictionaries are not equal", function()
- local dictionary1 = { hello = "world", goodbye = "world" }
- local dictionary2 = { hello = "world", goodbye = "world2" }
-
- expect(Equals(dictionary1, dictionary2)).to.equal(false)
- end)
-
- it("should return false for nested dictionaries", function()
- --[[
- This is because the nested dictionaries have different memory addresses,
- despite having the same values. Use EqualsDeep instead if you want to
- compare nested dictionaries.
- --]]
- local dictionary1 = { hello = "world", goodbye = { world = "hello" } }
- local dictionary2 = { hello = "world", goodbye = { world = "hello" } }
-
- expect(Equals(dictionary1, dictionary2)).to.equal(false)
- end)
-end
diff --git a/src/Dictionary/equalsDeep.spec.lua b/src/Dictionary/equalsDeep.spec.lua
deleted file mode 100644
index bbcd256..0000000
--- a/src/Dictionary/equalsDeep.spec.lua
+++ /dev/null
@@ -1,26 +0,0 @@
-return function()
- local EqualsDeep = require(script.Parent.equalsDeep)
-
- it("should return true if the dictionaries are equal", function()
- local dictionary1 = { hello = "world", goodbye = "world" }
- local dictionary2 = { hello = "world", goodbye = "world" }
-
- expect(EqualsDeep(dictionary1, dictionary2)).to.equal(true)
- end)
-
- it("should return false if the dictionaries are not equal", function()
- local dictionary1 = { hello = "world", goodbye = "world" }
- local dictionary2 = { hello = "world", goodbye = "world2" }
-
- expect(EqualsDeep(dictionary1, dictionary2)).to.equal(false)
- end)
-
- it("should return true for nested dictionaries", function()
- local dictionary1 = { hello = "world", goodbye = { world = "hello" } }
- local dictionary2 = { hello = "world", goodbye = { world = "hello" } }
- local dictionary3 = { hello = "world", goodbye = { world = "world" } }
-
- expect(EqualsDeep(dictionary1, dictionary2)).to.equal(true)
- expect(EqualsDeep(dictionary1, dictionary3)).to.equal(false)
- end)
-end
diff --git a/src/Dictionary/every.spec.lua b/src/Dictionary/every.spec.lua
deleted file mode 100644
index 3717db7..0000000
--- a/src/Dictionary/every.spec.lua
+++ /dev/null
@@ -1,19 +0,0 @@
-return function()
- local Every = require(script.Parent.every)
-
- it("should return true if all elements match the predicate", function()
- local dictionary = { hello = "world", goodbye = "world" }
-
- expect(Every(dictionary, function(value)
- return value == "world"
- end)).to.equal(true)
- end)
-
- it("should return false if any elements do not match the predicate", function()
- local dictionary = { hello = "world", goodbye = "world" }
-
- expect(Every(dictionary, function(value)
- return value == "hello"
- end)).to.equal(false)
- end)
-end
diff --git a/src/Dictionary/filter.spec.lua b/src/Dictionary/filter.spec.lua
deleted file mode 100644
index dc9bcf2..0000000
--- a/src/Dictionary/filter.spec.lua
+++ /dev/null
@@ -1,34 +0,0 @@
-return function()
- local Filter = require(script.Parent.filter)
-
- it(
- "should return a copy of the given dictionary with only the elements that match the predicate",
- function()
- local dictionary = { hello = "world", goodbye = "goodbye" }
-
- local new = Filter(dictionary, function(value)
- return value == "world"
- end)
-
- expect(new).to.be.a("table")
- expect(new).never.to.equal(dictionary)
-
- expect(new.hello).to.equal("world")
- end
- )
-
- it("should not modify the original dictionary", function()
- local dictionary = { hello = "world", goodbye = "goodbye" }
-
- local new = Filter(dictionary, function(value)
- return value == "world"
- end)
-
- expect(new).never.to.equal(dictionary)
-
- expect(dictionary.hello).to.equal("world")
- expect(dictionary.goodbye).to.equal("goodbye")
-
- expect(new.hello).to.equal("world")
- end)
-end
diff --git a/src/Dictionary/flatten.spec.lua b/src/Dictionary/flatten.spec.lua
deleted file mode 100644
index 5e896bf..0000000
--- a/src/Dictionary/flatten.spec.lua
+++ /dev/null
@@ -1,64 +0,0 @@
-return function()
- local Flatten = require(script.Parent.flatten)
-
- it("should return a flattened dictionary", function()
- local dictionary = {
- hello = "world",
- goodbye = {
- yes = "no",
- no = "yes",
- },
- }
-
- local flattened = Flatten(dictionary)
-
- expect(flattened).to.be.a("table")
-
- expect(flattened.hello).to.equal("world")
- expect(flattened.yes).to.equal("no")
- expect(flattened.no).to.equal("yes")
- end)
-
- it("should not flatten nested dictionaries if depth = 0", function()
- local dictionary = {
- hello = "world",
- goodbye = {
- yes = "no",
- no = "yes",
- },
- }
-
- local flattened = Flatten(dictionary, 0)
-
- expect(flattened).to.be.a("table")
-
- expect(flattened.hello).to.equal("world")
- expect(flattened.goodbye).to.equal(dictionary.goodbye)
- end)
-
- it("should flatten as deeply as possible", function()
- local dictionary = {
- hello = "world",
- goodbye = {
- yes = "no",
- no = "yes",
- maybe = {
- maybe = "ok",
- okay = {
- experience = "roblox",
- },
- },
- },
- }
-
- local flattened = Flatten(dictionary)
-
- expect(flattened).to.be.a("table")
-
- expect(flattened.hello).to.equal("world")
- expect(flattened.yes).to.equal("no")
- expect(flattened.no).to.equal("yes")
- expect(flattened.maybe).to.equal("ok")
- expect(flattened.experience).to.equal("roblox")
- end)
-end
diff --git a/src/Dictionary/flip.spec.lua b/src/Dictionary/flip.spec.lua
deleted file mode 100644
index 4015a18..0000000
--- a/src/Dictionary/flip.spec.lua
+++ /dev/null
@@ -1,14 +0,0 @@
-return function()
- local Flip = require(script.Parent.flip)
-
- it("should return a flipped dictionary", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local new = Flip(dictionary)
-
- expect(new).to.be.a("table")
-
- expect(new.world).to.equal("goodbye")
- expect(new.roblox).to.equal("hello")
- end)
-end
diff --git a/src/Dictionary/freeze.spec.lua b/src/Dictionary/freeze.spec.lua
deleted file mode 100644
index 090d1b1..0000000
--- a/src/Dictionary/freeze.spec.lua
+++ /dev/null
@@ -1,42 +0,0 @@
-return function()
- local Freeze = require(script.Parent.freeze)
-
- it("should return a read-only copy of the given dictionary", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local frozen = Freeze(dictionary)
-
- expect(frozen).to.be.a("table")
- expect(frozen).never.to.equal(dictionary)
-
- expect(frozen.hello).to.equal("roblox")
- expect(frozen.goodbye).to.equal("world")
-
- expect(function()
- frozen.hello = "world"
- end).to.throw()
- end)
-
- it("should not freeze nested dictionaries", function()
- local dictionary = { hello = "roblox", goodbye = { world = "goodbye" } }
-
- local frozen = Freeze(dictionary)
-
- expect(frozen).to.be.a("table")
- expect(frozen).never.to.equal(dictionary)
-
- expect(frozen.hello).to.equal("roblox")
- expect(frozen.goodbye).to.be.a("table")
- expect(frozen.goodbye).to.equal(dictionary.goodbye)
-
- expect(frozen.goodbye.world).to.equal("goodbye")
-
- expect(function()
- frozen.hello = "world"
- end).to.throw()
-
- expect(function()
- frozen.goodbye.world = "hello"
- end).never.to.throw()
- end)
-end
diff --git a/src/Dictionary/freezeDeep.spec.lua b/src/Dictionary/freezeDeep.spec.lua
deleted file mode 100644
index 699ea4d..0000000
--- a/src/Dictionary/freezeDeep.spec.lua
+++ /dev/null
@@ -1,43 +0,0 @@
-return function()
- local FreezeDeep = require(script.Parent.freezeDeep)
-
- it("should return a read-only copy of the given dictionary", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local frozen = FreezeDeep(dictionary)
-
- expect(frozen).to.be.a("table")
- expect(frozen).never.to.equal(dictionary)
-
- expect(frozen.hello).to.equal("roblox")
- expect(frozen.goodbye).to.equal("world")
-
- expect(function()
- frozen.hello = "world"
- end).to.throw()
- end)
-
- it("should freeze nested dictionaries", function()
- local dictionary = { hello = "roblox", goodbye = { world = "goodbye" } }
-
- local frozen = FreezeDeep(dictionary)
-
- expect(frozen).to.be.a("table")
- expect(frozen).never.to.equal(dictionary)
-
- expect(frozen.hello).to.equal("roblox")
-
- expect(frozen.goodbye).to.be.a("table")
- expect(frozen.goodbye).never.to.equal(dictionary.goodbye)
-
- expect(frozen.goodbye.world).to.equal("goodbye")
-
- expect(function()
- frozen.hello = "world"
- end).to.throw()
-
- expect(function()
- frozen.goodbye.world = "hello"
- end).to.throw()
- end)
-end
diff --git a/src/Dictionary/fromArrays.spec.lua b/src/Dictionary/fromArrays.spec.lua
deleted file mode 100644
index 0b9530e..0000000
--- a/src/Dictionary/fromArrays.spec.lua
+++ /dev/null
@@ -1,15 +0,0 @@
-return function()
- local FromArrays = require(script.Parent.fromArrays)
-
- it("should return a dictionary composed of the given keys and values", function()
- local keys = { "hello", "goodbye" }
- local values = { "roblox", "world" }
-
- local dictionary = FromArrays(keys, values)
-
- expect(dictionary).to.be.a("table")
-
- expect(dictionary.hello).to.equal("roblox")
- expect(dictionary.goodbye).to.equal("world")
- end)
-end
diff --git a/src/Dictionary/fromEntries.spec.lua b/src/Dictionary/fromEntries.spec.lua
deleted file mode 100644
index a3975de..0000000
--- a/src/Dictionary/fromEntries.spec.lua
+++ /dev/null
@@ -1,14 +0,0 @@
-return function()
- local FromEntries = require(script.Parent.fromEntries)
-
- it("should create a new dictionary from the given key-value pairs", function()
- local entries = { { "hello", "roblox" }, { "goodbye", "world" } }
-
- local dictionary = FromEntries(entries)
-
- expect(dictionary).to.be.a("table")
-
- expect(dictionary.hello).to.equal("roblox")
- expect(dictionary.goodbye).to.equal("world")
- end)
-end
diff --git a/src/Dictionary/has.spec.lua b/src/Dictionary/has.spec.lua
deleted file mode 100644
index 93a8bf9..0000000
--- a/src/Dictionary/has.spec.lua
+++ /dev/null
@@ -1,19 +0,0 @@
-return function()
- local Has = require(script.Parent.has)
-
- it("should return true if the dictionary has the given key", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local hasHello = Has(dictionary, "hello")
-
- expect(hasHello).to.equal(true)
- end)
-
- it("should return false if the dictionary does not have the given key", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local hasCat = Has(dictionary, "cat")
-
- expect(hasCat).to.equal(false)
- end)
-end
diff --git a/src/Dictionary/includes.spec.lua b/src/Dictionary/includes.spec.lua
deleted file mode 100644
index 64b8acf..0000000
--- a/src/Dictionary/includes.spec.lua
+++ /dev/null
@@ -1,19 +0,0 @@
-return function()
- local Includes = require(script.Parent.includes)
-
- it("should return true if the dictionary includes the given value", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local includesRoblox = Includes(dictionary, "roblox")
-
- expect(includesRoblox).to.equal(true)
- end)
-
- it("should return false if the dictionary does not include the given value", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local includesCat = Includes(dictionary, "cat")
-
- expect(includesCat).to.equal(false)
- end)
-end
diff --git a/src/Dictionary/keys.spec.lua b/src/Dictionary/keys.spec.lua
deleted file mode 100644
index 876458a..0000000
--- a/src/Dictionary/keys.spec.lua
+++ /dev/null
@@ -1,15 +0,0 @@
-return function()
- local Keys = require(script.Parent.keys)
-
- it("should return an array of the keys in the dictionary", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local keys = Keys(dictionary)
-
- expect(keys).to.be.a("table")
- expect(#keys).to.equal(2)
-
- expect(keys[1]).to.equal("hello")
- expect(keys[2]).to.equal("goodbye")
- end)
-end
diff --git a/src/Dictionary/map.spec.lua b/src/Dictionary/map.spec.lua
deleted file mode 100644
index 903be9b..0000000
--- a/src/Dictionary/map.spec.lua
+++ /dev/null
@@ -1,27 +0,0 @@
-return function()
- local Map = require(script.Parent.map)
-
- it("should return a dictionary where entries are the result of the mapper function", function()
- local dictionary = Map({ hello = "roblox", goodbye = "world" }, function(value)
- return value .. "!"
- end)
-
- expect(dictionary).to.be.a("table")
-
- expect(dictionary.hello).to.equal("roblox!")
- expect(dictionary.goodbye).to.equal("world!")
- end)
-
- it("should not modify the original dictionary", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- Map(dictionary, function(value)
- return value .. "!"
- end)
-
- expect(dictionary).to.be.a("table")
-
- expect(dictionary.hello).to.equal("roblox")
- expect(dictionary.goodbye).to.equal("world")
- end)
-end
diff --git a/src/Dictionary/merge.spec.lua b/src/Dictionary/merge.spec.lua
deleted file mode 100644
index ad727b6..0000000
--- a/src/Dictionary/merge.spec.lua
+++ /dev/null
@@ -1,61 +0,0 @@
-return function()
- local Merge = require(script.Parent.merge)
- local None = require(script.Parent.Parent.None)
-
- it(
- "should combine two or more dictionaries, where the last value overrides previous",
- function()
- local dictionary1 = { hello = "roblox", goodbye = "world" }
- local dictionary2 = { hello = "hello" }
-
- local merged = Merge(dictionary1, dictionary2)
-
- expect(merged).to.be.a("table")
-
- expect(merged.hello).to.equal("hello")
- expect(merged.goodbye).to.equal("world")
- end
- )
-
- it("should not modify the original dictionaries", function()
- local dictionary1 = { hello = "roblox", goodbye = "world" }
- local dictionary2 = { hello = "hello" }
-
- Merge(dictionary1, dictionary2)
-
- expect(dictionary1).to.be.a("table")
- expect(dictionary2).to.be.a("table")
-
- expect(dictionary1.hello).to.equal("roblox")
- expect(dictionary2.hello).to.equal("hello")
- end)
-
- it("should accept nil values", function()
- local dictionary1 = { hello = "roblox", goodbye = "world" }
-
- local merged = Merge(dictionary1, nil)
- local merged2 = Merge(nil, dictionary1)
-
- expect(merged).to.be.a("table")
-
- expect(merged.hello).to.equal("roblox")
- expect(merged.goodbye).to.equal("world")
-
- expect(merged2).to.be.a("table")
-
- expect(merged2.hello).to.equal("roblox")
- expect(merged2.goodbye).to.equal("world")
- end)
-
- it("should remove values set to None", function()
- local dictionary1 = { hello = "roblox", goodbye = "world" }
- local dictionary2 = { goodbye = None }
-
- local merged = Merge(dictionary1, dictionary2)
-
- expect(merged).to.be.a("table")
-
- expect(merged.hello).to.equal("roblox")
- expect(merged.goodbye).to.equal(nil)
- end)
-end
diff --git a/src/Dictionary/mergeDeep.spec.lua b/src/Dictionary/mergeDeep.spec.lua
deleted file mode 100644
index 526149f..0000000
--- a/src/Dictionary/mergeDeep.spec.lua
+++ /dev/null
@@ -1,61 +0,0 @@
-return function()
- local MergeDeep = require(script.Parent.mergeDeep)
- local None = require(script.Parent.Parent.None)
-
- it(
- "should combine two or more dictionaries, where the last value overrides previous, recursively",
- function()
- local dictionary1 = { hello = "roblox", goodbye = { world = "world" } }
- local dictionary2 = { goodbye = { world = "hello" } }
-
- local merged = MergeDeep(dictionary1, dictionary2)
-
- expect(merged).to.be.a("table")
-
- expect(merged.hello).to.equal("roblox")
- expect(merged.goodbye.world).to.equal("hello")
- end
- )
-
- it("should not modify the original dictionaries", function()
- local dictionary1 = { hello = "roblox", goodbye = { world = "world" } }
- local dictionary2 = { goodbye = { world = "hello" } }
-
- MergeDeep(dictionary1, dictionary2)
-
- expect(dictionary1).to.be.a("table")
- expect(dictionary2).to.be.a("table")
-
- expect(dictionary1.hello).to.equal("roblox")
- expect(dictionary1.goodbye.world).to.equal("world")
- end)
-
- it("should accept nil values", function()
- local dictionary1 = { hello = "roblox", goodbye = { world = "world" } }
-
- local merged = MergeDeep(dictionary1, nil)
- local merged2 = MergeDeep(nil, dictionary1)
-
- expect(merged).to.be.a("table")
-
- expect(merged.hello).to.equal("roblox")
- expect(merged.goodbye.world).to.equal("world")
-
- expect(merged2).to.be.a("table")
-
- expect(merged2.hello).to.equal("roblox")
- expect(merged2.goodbye.world).to.equal("world")
- end)
-
- it("should remove values set to None", function()
- local dictionary1 = { hello = "roblox", goodbye = { world = "world" } }
- local dictionary2 = { goodbye = None }
-
- local merged = MergeDeep(dictionary1, dictionary2)
-
- expect(merged).to.be.a("table")
-
- expect(merged.hello).to.equal("roblox")
- expect(merged.goodbye).to.equal(nil)
- end)
-end
diff --git a/src/Dictionary/removeKey.spec.lua b/src/Dictionary/removeKey.spec.lua
deleted file mode 100644
index 302d33f..0000000
--- a/src/Dictionary/removeKey.spec.lua
+++ /dev/null
@@ -1,25 +0,0 @@
-return function()
- local RemoveKey = require(script.Parent.removeKey)
-
- it("should return a new dictionary with the given key removed", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local newDictionary = RemoveKey(dictionary, "goodbye")
-
- expect(newDictionary).to.be.a("table")
-
- expect(newDictionary.hello).to.equal("roblox")
- expect(newDictionary.goodbye).to.equal(nil)
- end)
-
- it("should not modify the original dictionary", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- RemoveKey(dictionary, "goodbye")
-
- expect(dictionary).to.be.a("table")
-
- expect(dictionary.hello).to.equal("roblox")
- expect(dictionary.goodbye).to.equal("world")
- end)
-end
diff --git a/src/Dictionary/removeKeys.spec.lua b/src/Dictionary/removeKeys.spec.lua
deleted file mode 100644
index d0ec246..0000000
--- a/src/Dictionary/removeKeys.spec.lua
+++ /dev/null
@@ -1,29 +0,0 @@
-return function()
- local RemoveKeys = require(script.Parent.removeKeys)
-
- it("should return a new dictionary with the given keys removed", function()
- local dictionary = { hello = "world", cat = "meow", dog = "woof", unicorn = "rainbow" }
-
- local newDictionary = RemoveKeys(dictionary, "cat", "dog")
-
- expect(newDictionary).to.be.a("table")
-
- expect(newDictionary.hello).to.equal("world")
- expect(newDictionary.cat).to.equal(nil)
- expect(newDictionary.dog).to.equal(nil)
- expect(newDictionary.unicorn).to.equal("rainbow")
- end)
-
- it("should not modify the original dictionary", function()
- local dictionary = { hello = "world", cat = "meow", dog = "woof", unicorn = "rainbow" }
-
- RemoveKeys(dictionary, "cat", "dog")
-
- expect(dictionary).to.be.a("table")
-
- expect(dictionary.hello).to.equal("world")
- expect(dictionary.cat).to.equal("meow")
- expect(dictionary.dog).to.equal("woof")
- expect(dictionary.unicorn).to.equal("rainbow")
- end)
-end
diff --git a/src/Dictionary/removeValue.spec.lua b/src/Dictionary/removeValue.spec.lua
deleted file mode 100644
index 2c6b533..0000000
--- a/src/Dictionary/removeValue.spec.lua
+++ /dev/null
@@ -1,25 +0,0 @@
-return function()
- local RemoveValue = require(script.Parent.removeValue)
-
- it("should return a new dictionary with the given value removed", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local newDictionary = RemoveValue(dictionary, "world")
-
- expect(newDictionary).to.be.a("table")
-
- expect(newDictionary.hello).to.equal("roblox")
- expect(newDictionary.goodbye).to.equal(nil)
- end)
-
- it("should not modify the original dictionary", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- RemoveValue(dictionary, "world")
-
- expect(dictionary).to.be.a("table")
-
- expect(dictionary.hello).to.equal("roblox")
- expect(dictionary.goodbye).to.equal("world")
- end)
-end
diff --git a/src/Dictionary/removeValues.spec.lua b/src/Dictionary/removeValues.spec.lua
deleted file mode 100644
index 31588d5..0000000
--- a/src/Dictionary/removeValues.spec.lua
+++ /dev/null
@@ -1,29 +0,0 @@
-return function()
- local RemoveValues = require(script.Parent.removeValues)
-
- it("should return a new dictionary with the given values removed", function()
- local dictionary = { hello = "world", goodbye = "world", cat = "meow", dog = "woof" }
-
- local newDictionary = RemoveValues(dictionary, "world")
-
- expect(newDictionary).to.be.a("table")
-
- expect(newDictionary.hello).to.equal(nil)
- expect(newDictionary.goodbye).to.equal(nil)
- expect(newDictionary.cat).to.equal("meow")
- expect(newDictionary.dog).to.equal("woof")
- end)
-
- it("should not modify the original dictionary", function()
- local dictionary = { hello = "world", goodbye = "world", cat = "meow", dog = "woof" }
-
- RemoveValues(dictionary, "world")
-
- expect(dictionary).to.be.a("table")
-
- expect(dictionary.hello).to.equal("world")
- expect(dictionary.goodbye).to.equal("world")
- expect(dictionary.cat).to.equal("meow")
- expect(dictionary.dog).to.equal("woof")
- end)
-end
diff --git a/src/Dictionary/set.spec.lua b/src/Dictionary/set.spec.lua
deleted file mode 100644
index 934f9d4..0000000
--- a/src/Dictionary/set.spec.lua
+++ /dev/null
@@ -1,25 +0,0 @@
-return function()
- local Set = require(script.Parent.set)
-
- it("should return a new dictionary with the given key/value set", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local newDictionary = Set(dictionary, "cat", "meow")
-
- expect(newDictionary).to.be.a("table")
-
- expect(newDictionary.hello).to.equal("roblox")
- expect(newDictionary.goodbye).to.equal("world")
- expect(newDictionary.cat).to.equal("meow")
- end)
-
- it("should not modify the original dictionary", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- Set(dictionary, "cat", "woof")
-
- expect(dictionary).to.be.a("table")
-
- expect(dictionary.cat).to.equal(nil)
- end)
-end
diff --git a/src/Dictionary/some.spec.lua b/src/Dictionary/some.spec.lua
deleted file mode 100644
index a784196..0000000
--- a/src/Dictionary/some.spec.lua
+++ /dev/null
@@ -1,23 +0,0 @@
-return function()
- local Some = require(script.Parent.some)
-
- it("should return true if the predicate returns true for any of the values", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local result = Some(dictionary, function(value)
- return value == "roblox"
- end)
-
- expect(result).to.equal(true)
- end)
-
- it("should return false if the predicate returns false for all of the values", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local result = Some(dictionary, function(value)
- return value == "hello"
- end)
-
- expect(result).to.equal(false)
- end)
-end
diff --git a/src/Dictionary/update.spec.lua b/src/Dictionary/update.spec.lua
deleted file mode 100644
index 35ca048..0000000
--- a/src/Dictionary/update.spec.lua
+++ /dev/null
@@ -1,57 +0,0 @@
-return function()
- local Update = require(script.Parent.update)
-
- it("should return a new dictionary with the given key updated", function()
- local dictionary = { cats = 2 }
-
- local new = Update(dictionary, "cats", function(value)
- return value + 1
- end)
-
- expect(new).to.be.a("table")
-
- expect(new.cats).to.equal(3)
- end)
-
- it("should not modify the original dictionary", function()
- local dictionary = { cats = 2 }
-
- Update(dictionary, "cats", function(value)
- return value + 1
- end)
-
- Update(dictionary, "dogs", nil, function()
- return 1
- end)
-
- expect(dictionary).to.be.a("table")
-
- expect(dictionary.cats).to.equal(2)
- expect(dictionary.dogs).to.equal(nil)
- end)
-
- it("should create the key if it does not exist", function()
- local dictionary = { cats = 2 }
-
- local new = Update(dictionary, "dogs", function(value)
- return value + 1
- end, function()
- return 1
- end)
-
- expect(new).to.be.a("table")
-
- expect(new.cats).to.equal(2)
- expect(new.dogs).to.equal(1)
- end)
-
- it("should not create a key if it doesn't exist and no callback is specified", function()
- local dictionary = { cats = 2 }
-
- local new = Update(dictionary, "dogs", function()
- return 1
- end)
-
- expect(new.dogs).to.equal(nil)
- end)
-end
diff --git a/src/Dictionary/values.spec.lua b/src/Dictionary/values.spec.lua
deleted file mode 100644
index 5891ddf..0000000
--- a/src/Dictionary/values.spec.lua
+++ /dev/null
@@ -1,15 +0,0 @@
-return function()
- local Values = require(script.Parent.values)
-
- it("should return a list of the values in the dictionary", function()
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local values = Values(dictionary)
-
- expect(values).to.be.a("table")
- expect(#values).to.equal(2)
-
- expect(values[1]).to.equal("roblox")
- expect(values[2]).to.equal("world")
- end)
-end
diff --git a/src/Dictionary/withKeys.spec.lua b/src/Dictionary/withKeys.spec.lua
deleted file mode 100644
index 623b660..0000000
--- a/src/Dictionary/withKeys.spec.lua
+++ /dev/null
@@ -1,29 +0,0 @@
-return function()
- local WithKeys = require(script.Parent.withKeys)
-
- it("should return a new dictionary with the given keys kept", function()
- local dictionary = { hello = "world", cat = "meow", dog = "woof", unicorn = "rainbow" }
-
- local newDictionary = WithKeys(dictionary, "cat", "dog")
-
- expect(newDictionary).to.be.a("table")
-
- expect(newDictionary.hello).to.equal(nil)
- expect(newDictionary.cat).to.equal("meow")
- expect(newDictionary.dog).to.equal("woof")
- expect(newDictionary.unicorn).to.equal(nil)
- end)
-
- it("should not modify the original dictionary", function()
- local dictionary = { hello = "world", cat = "meow", dog = "woof", unicorn = "rainbow" }
-
- WithKeys(dictionary, "cat", "dog")
-
- expect(dictionary).to.be.a("table")
-
- expect(dictionary.hello).to.equal("world")
- expect(dictionary.cat).to.equal("meow")
- expect(dictionary.dog).to.equal("woof")
- expect(dictionary.unicorn).to.equal("rainbow")
- end)
-end
diff --git a/src/Set/add.spec.lua b/src/Set/add.spec.lua
deleted file mode 100644
index 09ac8b3..0000000
--- a/src/Set/add.spec.lua
+++ /dev/null
@@ -1,25 +0,0 @@
-return function()
- local add = require(script.Parent.add)
-
- it("should add values to a set", function()
- local set = { hello = true }
-
- local newSet = add(set, "world")
-
- expect(newSet).to.be.a("table")
-
- expect(newSet.hello).to.equal(true)
- expect(newSet.world).to.equal(true)
- end)
-
- it("should not modify the original set", function()
- local set = { hello = true }
-
- add(set, "world")
-
- expect(set).to.be.a("table")
-
- expect(set.hello).to.equal(true)
- expect(set.world).to.equal(nil)
- end)
-end
diff --git a/src/Set/copy.spec.lua b/src/Set/copy.spec.lua
deleted file mode 100644
index 21e9dd0..0000000
--- a/src/Set/copy.spec.lua
+++ /dev/null
@@ -1,14 +0,0 @@
-return function()
- local copy = require(script.Parent.copy)
-
- it("should copy a set", function()
- local set = { hello = true }
-
- local newSet = copy(set)
-
- expect(newSet).to.be.a("table")
- expect(newSet).never.to.equal(set)
-
- expect(newSet.hello).to.equal(true)
- end)
-end
diff --git a/src/Set/count.spec.lua b/src/Set/count.spec.lua
deleted file mode 100644
index 14b5638..0000000
--- a/src/Set/count.spec.lua
+++ /dev/null
@@ -1,17 +0,0 @@
-return function()
- local count = require(script.Parent.count)
-
- it("should count the number of values in a set", function()
- local set = { hello = true, world = true }
-
- expect(count(set)).to.equal(2)
- end)
-
- it("should count the number of values in a set matching the predicate", function()
- local set = { hello = true, world = true }
-
- expect(count(set, function(value)
- return value == "hello"
- end)).to.equal(1)
- end)
-end
diff --git a/src/Set/delete.spec.lua b/src/Set/delete.spec.lua
deleted file mode 100644
index 3ebb89d..0000000
--- a/src/Set/delete.spec.lua
+++ /dev/null
@@ -1,23 +0,0 @@
-return function()
- local delete = require(script.Parent.delete)
-
- it("should delete a value from a set", function()
- local set = { hello = true }
-
- local newSet = delete(set, "hello")
-
- expect(newSet).to.be.a("table")
- expect(newSet).never.to.equal(set)
-
- expect(newSet.hello).to.equal(nil)
- end)
-
- it("should not modify the original set", function()
- local set = { hello = true }
-
- delete(set, "hello")
-
- expect(set).to.be.a("table")
- expect(set.hello).to.equal(true)
- end)
-end
diff --git a/src/Set/difference.spec.lua b/src/Set/difference.spec.lua
deleted file mode 100644
index eba8c07..0000000
--- a/src/Set/difference.spec.lua
+++ /dev/null
@@ -1,43 +0,0 @@
-return function()
- local difference = require(script.Parent.difference)
-
- it("should return the difference between two sets", function()
- local set = { hello = true, world = true }
- local otherSet = { panda = true, cat = true }
-
- local newSet = difference(set, otherSet)
-
- expect(newSet).to.be.a("table")
-
- expect(newSet.hello).to.equal(true)
- expect(newSet.world).to.equal(true)
- expect(newSet.panda).to.equal(nil)
- expect(newSet.cat).to.equal(nil)
- end)
-
- it("should accept vararg nil values", function()
- local set = { hello = true, world = true }
- local otherSet = { panda = true, cat = true }
-
- local newSet = difference(set, nil, otherSet)
-
- expect(newSet).to.be.a("table")
- expect(newSet.hello).to.equal(true)
- expect(newSet.panda).to.equal(nil)
- end)
-
- it("should accept multiple sets", function()
- local set = { hello = true, world = true }
- local otherSet = { panda = true, cat = true }
- local anotherSet = { hello = true, panda = true }
-
- local newSet = difference(set, otherSet, anotherSet)
-
- expect(newSet).to.be.a("table")
-
- expect(newSet.hello).to.equal(nil)
- expect(newSet.world).to.equal(true)
- expect(newSet.panda).to.equal(nil)
- expect(newSet.cat).to.equal(nil)
- end)
-end
diff --git a/src/Set/differenceSymmetric.spec.lua b/src/Set/differenceSymmetric.spec.lua
deleted file mode 100644
index 54a78d8..0000000
--- a/src/Set/differenceSymmetric.spec.lua
+++ /dev/null
@@ -1,43 +0,0 @@
-return function()
- local differenceSymmetric = require(script.Parent.differenceSymmetric)
-
- it("should return the symmetric difference between two sets", function()
- local set = { hello = true, world = true }
- local otherSet = { panda = true, cat = true }
-
- local newSet = differenceSymmetric(set, otherSet)
-
- expect(newSet).to.be.a("table")
-
- expect(newSet.hello).to.equal(true)
- expect(newSet.world).to.equal(true)
- expect(newSet.panda).to.equal(true)
- expect(newSet.cat).to.equal(true)
- end)
-
- it("should accept vararg nil values", function()
- local set = { hello = true, world = true }
- local otherSet = { panda = true, cat = true }
-
- local newSet = differenceSymmetric(set, nil, otherSet)
-
- expect(newSet).to.be.a("table")
- expect(newSet.hello).to.equal(true)
- expect(newSet.panda).to.equal(true)
- end)
-
- it("should accept multiple sets", function()
- local set = { hello = true, world = true }
- local otherSet = { panda = true, cat = true }
- local anotherSet = { hello = true, panda = true }
-
- local newSet = differenceSymmetric(set, otherSet, anotherSet)
-
- expect(newSet).to.be.a("table")
-
- expect(newSet.hello).to.equal(nil)
- expect(newSet.world).to.equal(true)
- expect(newSet.panda).to.equal(nil)
- expect(newSet.cat).to.equal(true)
- end)
-end
diff --git a/src/Set/filter.spec.lua b/src/Set/filter.spec.lua
deleted file mode 100644
index 6e76422..0000000
--- a/src/Set/filter.spec.lua
+++ /dev/null
@@ -1,28 +0,0 @@
-return function()
- local filter = require(script.Parent.filter)
-
- it("should filter a set", function()
- local set = { hello = true, world = true }
-
- local newSet = filter(set, function(value)
- return value ~= "hello"
- end)
-
- expect(newSet).to.be.a("table")
-
- expect(newSet.hello).to.equal(nil)
- expect(newSet.world).to.equal(true)
- end)
-
- it("should not modify the original set", function()
- local set = { hello = true }
-
- filter(set, function(value)
- return value ~= "hello"
- end)
-
- expect(set).to.be.a("table")
-
- expect(set.hello).to.equal(true)
- end)
-end
diff --git a/src/Set/fromArray.spec.lua b/src/Set/fromArray.spec.lua
deleted file mode 100644
index 2dbc287..0000000
--- a/src/Set/fromArray.spec.lua
+++ /dev/null
@@ -1,12 +0,0 @@
-return function()
- local fromArray = require(script.Parent.fromArray)
-
- it("should create a set from an array", function()
- local set = fromArray({ "hello", "world" })
-
- expect(set).to.be.a("table")
-
- expect(set.hello).to.equal(true)
- expect(set.world).to.equal(true)
- end)
-end
diff --git a/src/Set/has.spec.lua b/src/Set/has.spec.lua
deleted file mode 100644
index 9023e63..0000000
--- a/src/Set/has.spec.lua
+++ /dev/null
@@ -1,10 +0,0 @@
-return function()
- local has = require(script.Parent.has)
-
- it("should check if a value is in a set", function()
- local set = { hello = true }
-
- expect(has(set, "hello")).to.equal(true)
- expect(has(set, "world")).to.equal(false)
- end)
-end
diff --git a/src/Set/intersection.spec.lua b/src/Set/intersection.spec.lua
deleted file mode 100644
index 2f23cfb..0000000
--- a/src/Set/intersection.spec.lua
+++ /dev/null
@@ -1,16 +0,0 @@
-return function()
- local intersection = require(script.Parent.intersection)
-
- it("should return the intersection of two sets", function()
- local set1 = { hello = true, world = true }
- local set2 = { world = true, cat = true }
-
- local newSet = intersection(set1, set2)
-
- expect(newSet).to.be.a("table")
-
- expect(newSet.hello).to.equal(nil)
- expect(newSet.world).to.equal(true)
- expect(newSet.cat).to.equal(nil)
- end)
-end
diff --git a/src/Set/isSubset.spec.lua b/src/Set/isSubset.spec.lua
deleted file mode 100644
index 78d541f..0000000
--- a/src/Set/isSubset.spec.lua
+++ /dev/null
@@ -1,11 +0,0 @@
-return function()
- local isSubset = require(script.Parent.isSubset)
-
- it("should check if a set is a subset of another set", function()
- local set = { hello = true, world = true }
- local otherSet = { hello = true }
-
- expect(isSubset(otherSet, set)).to.equal(true)
- expect(isSubset(set, otherSet)).to.equal(false)
- end)
-end
diff --git a/src/Set/isSuperset.spec.lua b/src/Set/isSuperset.spec.lua
deleted file mode 100644
index da25d55..0000000
--- a/src/Set/isSuperset.spec.lua
+++ /dev/null
@@ -1,11 +0,0 @@
-return function()
- local isSuperset = require(script.Parent.isSuperset)
-
- it("should check if a set is a superset of another set", function()
- local set = { hello = true, world = true }
- local otherSet = { hello = true }
-
- expect(isSuperset(set, otherSet)).to.equal(true)
- expect(isSuperset(otherSet, set)).to.equal(false)
- end)
-end
diff --git a/src/Set/map.spec.lua b/src/Set/map.spec.lua
deleted file mode 100644
index 04e9c14..0000000
--- a/src/Set/map.spec.lua
+++ /dev/null
@@ -1,32 +0,0 @@
-return function()
- local map = require(script.Parent.map)
-
- it("should map a set", function()
- local set = { hello = true, world = true }
-
- local newSet = map(set, function(value)
- return value .. "!"
- end)
-
- expect(newSet).to.be.a("table")
- expect(newSet).never.to.equal(set)
-
- expect(newSet.hello).to.equal(nil)
- expect(newSet.world).to.equal(nil)
-
- expect(newSet["hello!"]).to.equal(true)
- expect(newSet["world!"]).to.equal(true)
- end)
-
- it("should not modify the original set", function()
- local set = { hello = true }
-
- map(set, function(value)
- return value .. "!"
- end)
-
- expect(set).to.be.a("table")
-
- expect(set.hello).to.equal(true)
- end)
-end
diff --git a/src/Set/merge.spec.lua b/src/Set/merge.spec.lua
deleted file mode 100644
index 2f39f28..0000000
--- a/src/Set/merge.spec.lua
+++ /dev/null
@@ -1,33 +0,0 @@
-return function()
- local merge = require(script.Parent.merge)
-
- it("should merge two sets", function()
- local set = { hello = true, world = true }
- local otherSet = { panda = true, cat = true }
-
- local newSet = merge(set, otherSet)
-
- expect(newSet).to.be.a("table")
-
- expect(newSet.hello).to.equal(true)
- expect(newSet.world).to.equal(true)
- expect(newSet.panda).to.equal(true)
- expect(newSet.cat).to.equal(true)
- end)
-
- it("should accept nil values", function()
- local set = { hello = true, world = true }
- local otherSet = { panda = true, cat = true }
-
- local newSet = merge(set, nil, otherSet)
- local newSet2 = merge(nil, set, otherSet)
-
- expect(newSet).to.be.a("table")
- expect(newSet.hello).to.equal(true)
- expect(newSet.panda).to.equal(true)
-
- expect(newSet2).to.be.a("table")
- expect(newSet2.cat).to.equal(true)
- expect(newSet2.world).to.equal(true)
- end)
-end
diff --git a/src/Set/toArray.spec.lua b/src/Set/toArray.spec.lua
deleted file mode 100644
index ee2e46b..0000000
--- a/src/Set/toArray.spec.lua
+++ /dev/null
@@ -1,25 +0,0 @@
-return function()
- local toArray = require(script.Parent.toArray)
-
- it("should convert a set to an array", function()
- local set = { hello = true, world = true }
-
- local array = toArray(set)
-
- expect(array).to.be.a("table")
- expect(array).never.to.equal(set)
-
- expect(array[1]).to.equal("hello")
- expect(array[2]).to.equal("world")
- end)
-
- it("should not modify the original set", function()
- local set = { hello = true }
-
- toArray(set)
-
- expect(set).to.be.a("table")
-
- expect(set.hello).to.equal(true)
- end)
-end
diff --git a/src/init.lua b/src/init.lua
index 1b5c4f0..0882756 100644
--- a/src/init.lua
+++ b/src/init.lua
@@ -29,6 +29,8 @@ local Sift = {
equalObjects = require(script.Util.equalObjects),
isEmpty = require(script.Util.isEmpty),
+
+ meta = require(script.Metadata),
}
Sift.List = Sift.Array
diff --git a/stylua.toml b/stylua.toml
new file mode 100644
index 0000000..0fa95b6
--- /dev/null
+++ b/stylua.toml
@@ -0,0 +1,4 @@
+column_width = 96
+
+[sort_requires]
+enabled = true
diff --git a/wally.lock b/wally.lock
index e504397..bd4c484 100644
--- a/wally.lock
+++ b/wally.lock
@@ -4,5 +4,240 @@ registry = "test"
[[package]]
name = "csqrl/sift"
-version = "0.0.1"
+version = "0.0.9"
+dependencies = [["Jest", "jsdotlua/jest@3.6.1-rc.2"], ["JestGlobals", "jsdotlua/jest-globals@3.6.1-rc.2"]]
+
+[[package]]
+name = "jsdotlua/boolean"
+version = "1.2.6"
+dependencies = [["number", "jsdotlua/number@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/chalk"
+version = "0.2.1"
+dependencies = []
+
+[[package]]
+name = "jsdotlua/collections"
+version = "1.2.6"
+dependencies = [["es7-types", "jsdotlua/es7-types@1.2.6"], ["instance-of", "jsdotlua/instance-of@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/console"
+version = "1.2.6"
+dependencies = [["collections", "jsdotlua/collections@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/diff-sequences"
+version = "3.6.1-rc.2"
+dependencies = [["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/emittery"
+version = "3.6.1-rc.2"
+dependencies = [["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["promise", "jsdotlua/promise@3.5.2"]]
+
+[[package]]
+name = "jsdotlua/es7-types"
+version = "1.2.6"
+dependencies = []
+
+[[package]]
+name = "jsdotlua/expect"
+version = "3.6.1-rc.2"
+dependencies = [["jest-get-type", "jsdotlua/jest-get-type@3.6.1-rc.2"], ["jest-matcher-utils", "jsdotlua/jest-matcher-utils@3.6.1-rc.2"], ["jest-message-util", "jsdotlua/jest-message-util@3.6.1-rc.2"], ["jest-roblox-shared", "jsdotlua/jest-roblox-shared@3.6.1-rc.2"], ["jest-snapshot", "jsdotlua/jest-snapshot@3.6.1-rc.2"], ["jest-util", "jsdotlua/jest-util@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["luau-regexp", "jsdotlua/luau-regexp@0.2.1"], ["promise", "jsdotlua/promise@3.5.2"]]
+
+[[package]]
+name = "jsdotlua/instance-of"
+version = "1.2.6"
dependencies = []
+
+[[package]]
+name = "jsdotlua/jest"
+version = "3.6.1-rc.2"
+dependencies = [["jest-core", "jsdotlua/jest-core@3.6.1-rc.2"]]
+
+[[package]]
+name = "jsdotlua/jest-circus"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["expect", "jsdotlua/expect@3.6.1-rc.2"], ["jest-each", "jsdotlua/jest-each@3.6.1-rc.2"], ["jest-environment", "jsdotlua/jest-environment@3.6.1-rc.2"], ["jest-matcher-utils", "jsdotlua/jest-matcher-utils@3.6.1-rc.2"], ["jest-message-util", "jsdotlua/jest-message-util@3.6.1-rc.2"], ["jest-roblox-shared", "jsdotlua/jest-roblox-shared@3.6.1-rc.2"], ["jest-runtime", "jsdotlua/jest-runtime@3.6.1-rc.2"], ["jest-snapshot", "jsdotlua/jest-snapshot@3.6.1-rc.2"], ["jest-test-result", "jsdotlua/jest-test-result@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["jest-util", "jsdotlua/jest-util@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["luau-regexp", "jsdotlua/luau-regexp@0.2.1"], ["pretty-format", "jsdotlua/pretty-format@3.6.1-rc.2"], ["promise", "jsdotlua/promise@3.5.2"], ["throat", "jsdotlua/throat@3.6.1-rc.2"]]
+
+[[package]]
+name = "jsdotlua/jest-config"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["jest-each", "jsdotlua/jest-each@3.6.1-rc.2"], ["jest-environment-roblox", "jsdotlua/jest-environment-roblox@3.6.1-rc.2"], ["jest-get-type", "jsdotlua/jest-get-type@3.6.1-rc.2"], ["jest-message-util", "jsdotlua/jest-message-util@3.6.1-rc.2"], ["jest-roblox-shared", "jsdotlua/jest-roblox-shared@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["jest-util", "jsdotlua/jest-util@3.6.1-rc.2"], ["jest-validate", "jsdotlua/jest-validate@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["luau-regexp", "jsdotlua/luau-regexp@0.2.1"], ["promise", "jsdotlua/promise@3.5.2"]]
+
+[[package]]
+name = "jsdotlua/jest-console"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["jest-each", "jsdotlua/jest-each@3.6.1-rc.2"], ["jest-message-util", "jsdotlua/jest-message-util@3.6.1-rc.2"], ["jest-mock", "jsdotlua/jest-mock@3.6.1-rc.2"], ["jest-roblox-shared", "jsdotlua/jest-roblox-shared@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["jest-util", "jsdotlua/jest-util@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/jest-core"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["emittery", "jsdotlua/emittery@3.6.1-rc.2"], ["jest-config", "jsdotlua/jest-config@3.6.1-rc.2"], ["jest-console", "jsdotlua/jest-console@3.6.1-rc.2"], ["jest-message-util", "jsdotlua/jest-message-util@3.6.1-rc.2"], ["jest-reporters", "jsdotlua/jest-reporters@3.6.1-rc.2"], ["jest-roblox-shared", "jsdotlua/jest-roblox-shared@3.6.1-rc.2"], ["jest-runner", "jsdotlua/jest-runner@3.6.1-rc.2"], ["jest-runtime", "jsdotlua/jest-runtime@3.6.1-rc.2"], ["jest-snapshot", "jsdotlua/jest-snapshot@3.6.1-rc.2"], ["jest-test-result", "jsdotlua/jest-test-result@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["jest-util", "jsdotlua/jest-util@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["luau-regexp", "jsdotlua/luau-regexp@0.2.1"], ["pretty-format", "jsdotlua/pretty-format@3.6.1-rc.2"], ["promise", "jsdotlua/promise@3.5.2"]]
+
+[[package]]
+name = "jsdotlua/jest-diff"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["diff-sequences", "jsdotlua/diff-sequences@3.6.1-rc.2"], ["jest-get-type", "jsdotlua/jest-get-type@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["pretty-format", "jsdotlua/pretty-format@3.6.1-rc.2"]]
+
+[[package]]
+name = "jsdotlua/jest-each"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["jest-get-type", "jsdotlua/jest-get-type@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["jest-util", "jsdotlua/jest-util@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["luau-regexp", "jsdotlua/luau-regexp@0.2.1"], ["pretty-format", "jsdotlua/pretty-format@3.6.1-rc.2"]]
+
+[[package]]
+name = "jsdotlua/jest-environment"
+version = "3.6.1-rc.2"
+dependencies = [["jest-fake-timers", "jsdotlua/jest-fake-timers@3.6.1-rc.2"], ["jest-mock", "jsdotlua/jest-mock@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/jest-environment-roblox"
+version = "3.6.1-rc.2"
+dependencies = [["jest-environment", "jsdotlua/jest-environment@3.6.1-rc.2"], ["jest-fake-timers", "jsdotlua/jest-fake-timers@3.6.1-rc.2"], ["jest-mock", "jsdotlua/jest-mock@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["promise", "jsdotlua/promise@3.5.2"]]
+
+[[package]]
+name = "jsdotlua/jest-fake-timers"
+version = "3.6.1-rc.2"
+dependencies = [["jest-get-type", "jsdotlua/jest-get-type@3.6.1-rc.2"], ["jest-mock", "jsdotlua/jest-mock@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/jest-get-type"
+version = "3.6.1-rc.2"
+dependencies = [["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["luau-regexp", "jsdotlua/luau-regexp@0.2.1"]]
+
+[[package]]
+name = "jsdotlua/jest-globals"
+version = "3.6.1-rc.2"
+dependencies = [["expect", "jsdotlua/expect@3.6.1-rc.2"], ["jest-environment", "jsdotlua/jest-environment@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/jest-matcher-utils"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["jest-diff", "jsdotlua/jest-diff@3.6.1-rc.2"], ["jest-get-type", "jsdotlua/jest-get-type@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["luau-regexp", "jsdotlua/luau-regexp@0.2.1"], ["pretty-format", "jsdotlua/pretty-format@3.6.1-rc.2"]]
+
+[[package]]
+name = "jsdotlua/jest-message-util"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["jest-roblox-shared", "jsdotlua/jest-roblox-shared@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["luau-regexp", "jsdotlua/luau-regexp@0.2.1"], ["pretty-format", "jsdotlua/pretty-format@3.6.1-rc.2"]]
+
+[[package]]
+name = "jsdotlua/jest-mock"
+version = "3.6.1-rc.2"
+dependencies = [["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/jest-reporters"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["jest-console", "jsdotlua/jest-console@3.6.1-rc.2"], ["jest-message-util", "jsdotlua/jest-message-util@3.6.1-rc.2"], ["jest-mock", "jsdotlua/jest-mock@3.6.1-rc.2"], ["jest-roblox-shared", "jsdotlua/jest-roblox-shared@3.6.1-rc.2"], ["jest-test-result", "jsdotlua/jest-test-result@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["jest-util", "jsdotlua/jest-util@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["path", "jsdotlua/path@3.6.1-rc.2"]]
+
+[[package]]
+name = "jsdotlua/jest-roblox-shared"
+version = "3.6.1-rc.2"
+dependencies = [["jest-get-type", "jsdotlua/jest-get-type@3.6.1-rc.2"], ["jest-mock", "jsdotlua/jest-mock@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/jest-runner"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["emittery", "jsdotlua/emittery@3.6.1-rc.2"], ["jest-circus", "jsdotlua/jest-circus@3.6.1-rc.2"], ["jest-console", "jsdotlua/jest-console@3.6.1-rc.2"], ["jest-environment", "jsdotlua/jest-environment@3.6.1-rc.2"], ["jest-message-util", "jsdotlua/jest-message-util@3.6.1-rc.2"], ["jest-roblox-shared", "jsdotlua/jest-roblox-shared@3.6.1-rc.2"], ["jest-runtime", "jsdotlua/jest-runtime@3.6.1-rc.2"], ["jest-test-result", "jsdotlua/jest-test-result@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["jest-util", "jsdotlua/jest-util@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["pretty-format", "jsdotlua/pretty-format@3.6.1-rc.2"], ["promise", "jsdotlua/promise@3.5.2"], ["throat", "jsdotlua/throat@3.6.1-rc.2"]]
+
+[[package]]
+name = "jsdotlua/jest-runtime"
+version = "3.6.1-rc.2"
+dependencies = [["emittery", "jsdotlua/emittery@3.6.1-rc.2"], ["expect", "jsdotlua/expect@3.6.1-rc.2"], ["jest-fake-timers", "jsdotlua/jest-fake-timers@3.6.1-rc.2"], ["jest-mock", "jsdotlua/jest-mock@3.6.1-rc.2"], ["jest-snapshot", "jsdotlua/jest-snapshot@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["promise", "jsdotlua/promise@3.5.2"]]
+
+[[package]]
+name = "jsdotlua/jest-snapshot"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["jest-diff", "jsdotlua/jest-diff@3.6.1-rc.2"], ["jest-get-type", "jsdotlua/jest-get-type@3.6.1-rc.2"], ["jest-matcher-utils", "jsdotlua/jest-matcher-utils@3.6.1-rc.2"], ["jest-roblox-shared", "jsdotlua/jest-roblox-shared@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["pretty-format", "jsdotlua/pretty-format@3.6.1-rc.2"], ["promise", "jsdotlua/promise@3.5.2"]]
+
+[[package]]
+name = "jsdotlua/jest-test-result"
+version = "3.6.1-rc.2"
+dependencies = [["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/jest-types"
+version = "3.6.1-rc.2"
+dependencies = [["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["luau-regexp", "jsdotlua/luau-regexp@0.2.1"]]
+
+[[package]]
+name = "jsdotlua/jest-util"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["jest-roblox-shared", "jsdotlua/jest-roblox-shared@3.6.1-rc.2"], ["jest-types", "jsdotlua/jest-types@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["luau-regexp", "jsdotlua/luau-regexp@0.2.1"], ["picomatch", "jsdotlua/picomatch@0.4.0"], ["promise", "jsdotlua/promise@3.5.2"]]
+
+[[package]]
+name = "jsdotlua/jest-validate"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/luau-polyfill"
+version = "1.2.6"
+dependencies = [["boolean", "jsdotlua/boolean@1.2.6"], ["collections", "jsdotlua/collections@1.2.6"], ["console", "jsdotlua/console@1.2.6"], ["es7-types", "jsdotlua/es7-types@1.2.6"], ["instance-of", "jsdotlua/instance-of@1.2.6"], ["math", "jsdotlua/math@1.2.6"], ["number", "jsdotlua/number@1.2.6"], ["string", "jsdotlua/string@1.2.6"], ["symbol-luau", "jsdotlua/symbol-luau@1.0.1"], ["timers", "jsdotlua/timers@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/luau-regexp"
+version = "0.2.1"
+dependencies = []
+
+[[package]]
+name = "jsdotlua/math"
+version = "1.2.6"
+dependencies = []
+
+[[package]]
+name = "jsdotlua/number"
+version = "1.2.6"
+dependencies = []
+
+[[package]]
+name = "jsdotlua/path"
+version = "3.6.1-rc.2"
+dependencies = [["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/picomatch"
+version = "0.4.0"
+dependencies = [["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["luau-regexp", "jsdotlua/luau-regexp@0.2.1"], ["promise", "jsdotlua/promise@3.5.2"]]
+
+[[package]]
+name = "jsdotlua/pretty-format"
+version = "3.6.1-rc.2"
+dependencies = [["chalk", "jsdotlua/chalk@0.2.1"], ["jest-get-type", "jsdotlua/jest-get-type@3.6.1-rc.2"], ["jest-roblox-shared", "jsdotlua/jest-roblox-shared@3.6.1-rc.2"], ["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["luau-regexp", "jsdotlua/luau-regexp@0.2.1"], ["react-is", "jsdotlua/react-is@17.1.0"]]
+
+[[package]]
+name = "jsdotlua/promise"
+version = "3.5.2"
+dependencies = []
+
+[[package]]
+name = "jsdotlua/react-is"
+version = "17.1.0"
+dependencies = [["shared", "jsdotlua/shared@17.1.0"]]
+
+[[package]]
+name = "jsdotlua/shared"
+version = "17.1.0"
+dependencies = [["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/string"
+version = "1.2.6"
+dependencies = [["es7-types", "jsdotlua/es7-types@1.2.6"], ["number", "jsdotlua/number@1.2.6"]]
+
+[[package]]
+name = "jsdotlua/symbol-luau"
+version = "1.0.1"
+dependencies = []
+
+[[package]]
+name = "jsdotlua/throat"
+version = "3.6.1-rc.2"
+dependencies = [["luau-polyfill", "jsdotlua/luau-polyfill@1.2.6"], ["promise", "jsdotlua/promise@3.5.2"]]
+
+[[package]]
+name = "jsdotlua/timers"
+version = "1.2.6"
+dependencies = [["collections", "jsdotlua/collections@1.2.6"]]
diff --git a/wally.toml b/wally.toml
index dd436fc..1ccbfd2 100644
--- a/wally.toml
+++ b/wally.toml
@@ -1,12 +1,12 @@
[package]
name = "csqrl/sift"
description = "Immutable data library for Luau"
-version = "0.0.8"
-license = "MIT"
-author = "csqrl (https://csqrl.dev)"
+version = "0.0.9"
registry = "https://github.com/upliftgames/wally-index"
-homepage = "https://csqrl.github.io/sift"
-repo = "https://github.com/csqrl/sift"
realm = "shared"
exclude = ["**"]
include = ["src", "src/**", "wally.toml", "wally.lock", "default.project.json"]
+
+[dev-dependencies]
+Jest = "jsdotlua/jest@3.6.1-rc.2"
+JestGlobals = "jsdotlua/jest-globals@3.6.1-rc.2"
From 87738d219441a4867667f30dc2180e2e42e7580f Mon Sep 17 00:00:00 2001
From: Cam <21029087+cxmeel@users.noreply.github.com>
Date: Mon, 11 Mar 2024 17:10:26 +0000
Subject: [PATCH 03/43] Move TS to `@types/...`
---
{src => @types}/Array.d.ts | 0
{src => @types}/Dictionary.d.ts | 0
{src => @types}/Set.d.ts | 0
{src => @types}/Util.d.ts | 0
{src => @types}/index.d.ts | 0
5 files changed, 0 insertions(+), 0 deletions(-)
rename {src => @types}/Array.d.ts (100%)
rename {src => @types}/Dictionary.d.ts (100%)
rename {src => @types}/Set.d.ts (100%)
rename {src => @types}/Util.d.ts (100%)
rename {src => @types}/index.d.ts (100%)
diff --git a/src/Array.d.ts b/@types/Array.d.ts
similarity index 100%
rename from src/Array.d.ts
rename to @types/Array.d.ts
diff --git a/src/Dictionary.d.ts b/@types/Dictionary.d.ts
similarity index 100%
rename from src/Dictionary.d.ts
rename to @types/Dictionary.d.ts
diff --git a/src/Set.d.ts b/@types/Set.d.ts
similarity index 100%
rename from src/Set.d.ts
rename to @types/Set.d.ts
diff --git a/src/Util.d.ts b/@types/Util.d.ts
similarity index 100%
rename from src/Util.d.ts
rename to @types/Util.d.ts
diff --git a/src/index.d.ts b/@types/index.d.ts
similarity index 100%
rename from src/index.d.ts
rename to @types/index.d.ts
From 02c8cea2eb7d5efcfc9f6dfc935094ce5c94d765 Mon Sep 17 00:00:00 2001
From: Cam <21029087+cxmeel@users.noreply.github.com>
Date: Mon, 11 Mar 2024 17:53:35 +0000
Subject: [PATCH 04/43] Convert *.lua to *.luau
---
.vscode/settings.json | 4 ++++
TestRunner.server.lua | 8 --------
default.project.json | 5 +----
selene.toml | 2 +-
serve.project.json | 12 ------------
sourcemap.json | 2 +-
src/Array/{at.lua => at.luau} | 0
src/Array/{concat.lua => concat.luau} | 0
src/Array/{concatDeep.lua => concatDeep.luau} | 0
src/Array/{copy.lua => copy.luau} | 0
src/Array/{copyDeep.lua => copyDeep.luau} | 0
src/Array/{count.lua => count.luau} | 0
src/Array/{create.lua => create.luau} | 0
src/Array/{difference.lua => difference.luau} | 0
...ferenceSymmetric.lua => differenceSymmetric.luau} | 0
src/Array/{equals.lua => equals.luau} | 0
src/Array/{equalsDeep.lua => equalsDeep.luau} | 0
src/Array/{every.lua => every.luau} | 0
src/Array/{filter.lua => filter.luau} | 0
src/Array/{find.lua => find.luau} | 0
src/Array/{findLast.lua => findLast.luau} | 0
src/Array/{findWhere.lua => findWhere.luau} | 0
src/Array/{findWhereLast.lua => findWhereLast.luau} | 0
src/Array/{first.lua => first.luau} | 0
src/Array/{flatten.lua => flatten.luau} | 0
src/Array/{freeze.lua => freeze.luau} | 0
src/Array/{freezeDeep.lua => freezeDeep.luau} | 0
src/Array/{includes.lua => includes.luau} | 0
src/Array/{init.lua => init.luau} | 0
src/Array/{insert.lua => insert.luau} | 0
src/Array/{is.lua => is.luau} | 0
src/Array/{last.lua => last.luau} | 0
src/Array/{map.lua => map.luau} | 0
src/Array/{pop.lua => pop.luau} | 0
src/Array/{push.lua => push.luau} | 0
src/Array/{reduce.lua => reduce.luau} | 0
src/Array/{reduceRight.lua => reduceRight.luau} | 0
src/Array/{removeIndex.lua => removeIndex.luau} | 0
src/Array/{removeIndices.lua => removeIndices.luau} | 0
src/Array/{removeValue.lua => removeValue.luau} | 0
src/Array/{removeValues.lua => removeValues.luau} | 0
src/Array/{reverse.lua => reverse.luau} | 0
src/Array/{set.lua => set.luau} | 0
src/Array/{shift.lua => shift.luau} | 0
src/Array/{shuffle.lua => shuffle.luau} | 0
src/Array/{slice.lua => slice.luau} | 0
src/Array/{some.lua => some.luau} | 0
src/Array/{sort.lua => sort.luau} | 0
src/Array/{splice.lua => splice.luau} | 0
src/Array/{toSet.lua => toSet.luau} | 0
src/Array/{unshift.lua => unshift.luau} | 0
src/Array/{update.lua => update.luau} | 0
src/Array/{zip.lua => zip.luau} | 0
src/Array/{zipAll.lua => zipAll.luau} | 0
src/Dictionary/{copy.lua => copy.luau} | 0
src/Dictionary/{copyDeep.lua => copyDeep.luau} | 0
src/Dictionary/{count.lua => count.luau} | 0
src/Dictionary/{entries.lua => entries.luau} | 0
src/Dictionary/{equals.lua => equals.luau} | 0
src/Dictionary/{equalsDeep.lua => equalsDeep.luau} | 0
src/Dictionary/{every.lua => every.luau} | 0
src/Dictionary/{filter.lua => filter.luau} | 0
src/Dictionary/{flatten.lua => flatten.luau} | 0
src/Dictionary/{flip.lua => flip.luau} | 0
src/Dictionary/{freeze.lua => freeze.luau} | 0
src/Dictionary/{freezeDeep.lua => freezeDeep.luau} | 0
src/Dictionary/{fromArrays.lua => fromArrays.luau} | 0
src/Dictionary/{fromEntries.lua => fromEntries.luau} | 0
src/Dictionary/{has.lua => has.luau} | 0
src/Dictionary/{includes.lua => includes.luau} | 0
src/Dictionary/{init.lua => init.luau} | 0
src/Dictionary/{keys.lua => keys.luau} | 0
src/Dictionary/{map.lua => map.luau} | 0
src/Dictionary/{merge.lua => merge.luau} | 0
src/Dictionary/{mergeDeep.lua => mergeDeep.luau} | 0
src/Dictionary/{removeKey.lua => removeKey.luau} | 0
src/Dictionary/{removeKeys.lua => removeKeys.luau} | 0
src/Dictionary/{removeValue.lua => removeValue.luau} | 0
.../{removeValues.lua => removeValues.luau} | 0
src/Dictionary/{set.lua => set.luau} | 0
src/Dictionary/{some.lua => some.luau} | 0
src/Dictionary/{update.lua => update.luau} | 0
src/Dictionary/{values.lua => values.luau} | 0
src/Dictionary/{withKeys.lua => withKeys.luau} | 0
src/{None.lua => None.luau} | 0
src/Set/{add.lua => add.luau} | 0
src/Set/{copy.lua => copy.luau} | 0
src/Set/{count.lua => count.luau} | 0
src/Set/{delete.lua => delete.luau} | 0
src/Set/{difference.lua => difference.luau} | 0
...ferenceSymmetric.lua => differenceSymmetric.luau} | 0
src/Set/{filter.lua => filter.luau} | 0
src/Set/{fromArray.lua => fromArray.luau} | 0
src/Set/{has.lua => has.luau} | 0
src/Set/{init.lua => init.luau} | 0
src/Set/{intersection.lua => intersection.luau} | 0
src/Set/{isSubset.lua => isSubset.luau} | 0
src/Set/{isSuperset.lua => isSuperset.luau} | 0
src/Set/{map.lua => map.luau} | 0
src/Set/{merge.lua => merge.luau} | 0
src/Set/{toArray.lua => toArray.luau} | 0
src/{Types.lua => Types.luau} | 0
src/Util/{equalObjects.lua => equalObjects.luau} | 0
src/Util/{func.lua => func.luau} | 0
src/Util/{init.lua => init.luau} | 0
src/Util/{isEmpty.lua => isEmpty.luau} | 0
src/{init.lua => init.luau} | 0
107 files changed, 7 insertions(+), 26 deletions(-)
delete mode 100644 TestRunner.server.lua
delete mode 100644 serve.project.json
rename src/Array/{at.lua => at.luau} (100%)
rename src/Array/{concat.lua => concat.luau} (100%)
rename src/Array/{concatDeep.lua => concatDeep.luau} (100%)
rename src/Array/{copy.lua => copy.luau} (100%)
rename src/Array/{copyDeep.lua => copyDeep.luau} (100%)
rename src/Array/{count.lua => count.luau} (100%)
rename src/Array/{create.lua => create.luau} (100%)
rename src/Array/{difference.lua => difference.luau} (100%)
rename src/Array/{differenceSymmetric.lua => differenceSymmetric.luau} (100%)
rename src/Array/{equals.lua => equals.luau} (100%)
rename src/Array/{equalsDeep.lua => equalsDeep.luau} (100%)
rename src/Array/{every.lua => every.luau} (100%)
rename src/Array/{filter.lua => filter.luau} (100%)
rename src/Array/{find.lua => find.luau} (100%)
rename src/Array/{findLast.lua => findLast.luau} (100%)
rename src/Array/{findWhere.lua => findWhere.luau} (100%)
rename src/Array/{findWhereLast.lua => findWhereLast.luau} (100%)
rename src/Array/{first.lua => first.luau} (100%)
rename src/Array/{flatten.lua => flatten.luau} (100%)
rename src/Array/{freeze.lua => freeze.luau} (100%)
rename src/Array/{freezeDeep.lua => freezeDeep.luau} (100%)
rename src/Array/{includes.lua => includes.luau} (100%)
rename src/Array/{init.lua => init.luau} (100%)
rename src/Array/{insert.lua => insert.luau} (100%)
rename src/Array/{is.lua => is.luau} (100%)
rename src/Array/{last.lua => last.luau} (100%)
rename src/Array/{map.lua => map.luau} (100%)
rename src/Array/{pop.lua => pop.luau} (100%)
rename src/Array/{push.lua => push.luau} (100%)
rename src/Array/{reduce.lua => reduce.luau} (100%)
rename src/Array/{reduceRight.lua => reduceRight.luau} (100%)
rename src/Array/{removeIndex.lua => removeIndex.luau} (100%)
rename src/Array/{removeIndices.lua => removeIndices.luau} (100%)
rename src/Array/{removeValue.lua => removeValue.luau} (100%)
rename src/Array/{removeValues.lua => removeValues.luau} (100%)
rename src/Array/{reverse.lua => reverse.luau} (100%)
rename src/Array/{set.lua => set.luau} (100%)
rename src/Array/{shift.lua => shift.luau} (100%)
rename src/Array/{shuffle.lua => shuffle.luau} (100%)
rename src/Array/{slice.lua => slice.luau} (100%)
rename src/Array/{some.lua => some.luau} (100%)
rename src/Array/{sort.lua => sort.luau} (100%)
rename src/Array/{splice.lua => splice.luau} (100%)
rename src/Array/{toSet.lua => toSet.luau} (100%)
rename src/Array/{unshift.lua => unshift.luau} (100%)
rename src/Array/{update.lua => update.luau} (100%)
rename src/Array/{zip.lua => zip.luau} (100%)
rename src/Array/{zipAll.lua => zipAll.luau} (100%)
rename src/Dictionary/{copy.lua => copy.luau} (100%)
rename src/Dictionary/{copyDeep.lua => copyDeep.luau} (100%)
rename src/Dictionary/{count.lua => count.luau} (100%)
rename src/Dictionary/{entries.lua => entries.luau} (100%)
rename src/Dictionary/{equals.lua => equals.luau} (100%)
rename src/Dictionary/{equalsDeep.lua => equalsDeep.luau} (100%)
rename src/Dictionary/{every.lua => every.luau} (100%)
rename src/Dictionary/{filter.lua => filter.luau} (100%)
rename src/Dictionary/{flatten.lua => flatten.luau} (100%)
rename src/Dictionary/{flip.lua => flip.luau} (100%)
rename src/Dictionary/{freeze.lua => freeze.luau} (100%)
rename src/Dictionary/{freezeDeep.lua => freezeDeep.luau} (100%)
rename src/Dictionary/{fromArrays.lua => fromArrays.luau} (100%)
rename src/Dictionary/{fromEntries.lua => fromEntries.luau} (100%)
rename src/Dictionary/{has.lua => has.luau} (100%)
rename src/Dictionary/{includes.lua => includes.luau} (100%)
rename src/Dictionary/{init.lua => init.luau} (100%)
rename src/Dictionary/{keys.lua => keys.luau} (100%)
rename src/Dictionary/{map.lua => map.luau} (100%)
rename src/Dictionary/{merge.lua => merge.luau} (100%)
rename src/Dictionary/{mergeDeep.lua => mergeDeep.luau} (100%)
rename src/Dictionary/{removeKey.lua => removeKey.luau} (100%)
rename src/Dictionary/{removeKeys.lua => removeKeys.luau} (100%)
rename src/Dictionary/{removeValue.lua => removeValue.luau} (100%)
rename src/Dictionary/{removeValues.lua => removeValues.luau} (100%)
rename src/Dictionary/{set.lua => set.luau} (100%)
rename src/Dictionary/{some.lua => some.luau} (100%)
rename src/Dictionary/{update.lua => update.luau} (100%)
rename src/Dictionary/{values.lua => values.luau} (100%)
rename src/Dictionary/{withKeys.lua => withKeys.luau} (100%)
rename src/{None.lua => None.luau} (100%)
rename src/Set/{add.lua => add.luau} (100%)
rename src/Set/{copy.lua => copy.luau} (100%)
rename src/Set/{count.lua => count.luau} (100%)
rename src/Set/{delete.lua => delete.luau} (100%)
rename src/Set/{difference.lua => difference.luau} (100%)
rename src/Set/{differenceSymmetric.lua => differenceSymmetric.luau} (100%)
rename src/Set/{filter.lua => filter.luau} (100%)
rename src/Set/{fromArray.lua => fromArray.luau} (100%)
rename src/Set/{has.lua => has.luau} (100%)
rename src/Set/{init.lua => init.luau} (100%)
rename src/Set/{intersection.lua => intersection.luau} (100%)
rename src/Set/{isSubset.lua => isSubset.luau} (100%)
rename src/Set/{isSuperset.lua => isSuperset.luau} (100%)
rename src/Set/{map.lua => map.luau} (100%)
rename src/Set/{merge.lua => merge.luau} (100%)
rename src/Set/{toArray.lua => toArray.luau} (100%)
rename src/{Types.lua => Types.luau} (100%)
rename src/Util/{equalObjects.lua => equalObjects.luau} (100%)
rename src/Util/{func.lua => func.luau} (100%)
rename src/Util/{init.lua => init.luau} (100%)
rename src/Util/{isEmpty.lua => isEmpty.luau} (100%)
rename src/{init.lua => init.luau} (100%)
diff --git a/.vscode/settings.json b/.vscode/settings.json
index 669c6bd..1acaf69 100644
--- a/.vscode/settings.json
+++ b/.vscode/settings.json
@@ -11,5 +11,9 @@
},
"[typescript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
+ },
+ "luau-lsp.require.directoryAliases": {
+ "@Pkg": "Packages",
+ "@DevPkg": "DevPackages"
}
}
diff --git a/TestRunner.server.lua b/TestRunner.server.lua
deleted file mode 100644
index e35a3a4..0000000
--- a/TestRunner.server.lua
+++ /dev/null
@@ -1,8 +0,0 @@
-local ServerScripts = game:GetService("ServerScriptService")
-local TestService = game:GetService("TestService")
-
-local TestEZ = require(TestService.Packages.TestEZ)
-
-TestEZ.TestBootstrap:run({
- ServerScripts.Sift,
-})
diff --git a/default.project.json b/default.project.json
index 43954a7..91c96e9 100644
--- a/default.project.json
+++ b/default.project.json
@@ -1,9 +1,6 @@
{
"name": "Sift",
"tree": {
- "$path": "src",
- "Metadata": {
- "$path": "wally.toml"
- }
+ "$path": "src"
}
}
diff --git a/selene.toml b/selene.toml
index c4ddb46..a30015a 100644
--- a/selene.toml
+++ b/selene.toml
@@ -1 +1 @@
-std = "roblox"
+std = "luau"
diff --git a/serve.project.json b/serve.project.json
deleted file mode 100644
index c664f99..0000000
--- a/serve.project.json
+++ /dev/null
@@ -1,12 +0,0 @@
-{
- "name": "SiftServe",
- "tree": {
- "$className": "DataModel",
- "ServerScriptService": {
- "$className": "ServerScriptService",
- "Sift": {
- "$path": "default.project.json"
- }
- }
- }
-}
diff --git a/sourcemap.json b/sourcemap.json
index b17927f..a41e6c4 100644
--- a/sourcemap.json
+++ b/sourcemap.json
@@ -1 +1 @@
-{"name":"Sift","className":"ModuleScript","filePaths":["src\\init.lua","default.project.json"],"children":[{"name":"Array","className":"ModuleScript","filePaths":["src\\Array\\init.lua"],"children":[{"name":"at","className":"ModuleScript","filePaths":["src\\Array\\at.lua"]},{"name":"concat","className":"ModuleScript","filePaths":["src\\Array\\concat.lua"]},{"name":"concatDeep","className":"ModuleScript","filePaths":["src\\Array\\concatDeep.lua"]},{"name":"copy","className":"ModuleScript","filePaths":["src\\Array\\copy.lua"]},{"name":"copyDeep","className":"ModuleScript","filePaths":["src\\Array\\copyDeep.lua"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Array\\count.lua"]},{"name":"create","className":"ModuleScript","filePaths":["src\\Array\\create.lua"]},{"name":"difference","className":"ModuleScript","filePaths":["src\\Array\\difference.lua"]},{"name":"differenceSymmetric","className":"ModuleScript","filePaths":["src\\Array\\differenceSymmetric.lua"]},{"name":"equals","className":"ModuleScript","filePaths":["src\\Array\\equals.lua"]},{"name":"equalsDeep","className":"ModuleScript","filePaths":["src\\Array\\equalsDeep.lua"]},{"name":"every","className":"ModuleScript","filePaths":["src\\Array\\every.lua"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Array\\filter.lua"]},{"name":"find","className":"ModuleScript","filePaths":["src\\Array\\find.lua"]},{"name":"findLast","className":"ModuleScript","filePaths":["src\\Array\\findLast.lua"]},{"name":"findWhere","className":"ModuleScript","filePaths":["src\\Array\\findWhere.lua"]},{"name":"findWhereLast","className":"ModuleScript","filePaths":["src\\Array\\findWhereLast.lua"]},{"name":"first","className":"ModuleScript","filePaths":["src\\Array\\first.lua"]},{"name":"flatten","className":"ModuleScript","filePaths":["src\\Array\\flatten.lua"]},{"name":"freeze","className":"ModuleScript","filePaths":["src\\Array\\freeze.lua"]},{"name":"freezeDeep","className":"ModuleScript","filePaths":["src\\Array\\freezeDeep.lua"]},{"name":"includes","className":"ModuleScript","filePaths":["src\\Array\\includes.lua"]},{"name":"insert","className":"ModuleScript","filePaths":["src\\Array\\insert.lua"]},{"name":"is","className":"ModuleScript","filePaths":["src\\Array\\is.lua"]},{"name":"last","className":"ModuleScript","filePaths":["src\\Array\\last.lua"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Array\\map.lua"]},{"name":"pop","className":"ModuleScript","filePaths":["src\\Array\\pop.lua"]},{"name":"push","className":"ModuleScript","filePaths":["src\\Array\\push.lua"]},{"name":"reduce","className":"ModuleScript","filePaths":["src\\Array\\reduce.lua"]},{"name":"reduceRight","className":"ModuleScript","filePaths":["src\\Array\\reduceRight.lua"]},{"name":"removeIndex","className":"ModuleScript","filePaths":["src\\Array\\removeIndex.lua"]},{"name":"removeIndices","className":"ModuleScript","filePaths":["src\\Array\\removeIndices.lua"]},{"name":"removeValue","className":"ModuleScript","filePaths":["src\\Array\\removeValue.lua"]},{"name":"removeValues","className":"ModuleScript","filePaths":["src\\Array\\removeValues.lua"]},{"name":"reverse","className":"ModuleScript","filePaths":["src\\Array\\reverse.lua"]},{"name":"set","className":"ModuleScript","filePaths":["src\\Array\\set.lua"]},{"name":"shift","className":"ModuleScript","filePaths":["src\\Array\\shift.lua"]},{"name":"shuffle","className":"ModuleScript","filePaths":["src\\Array\\shuffle.lua"]},{"name":"slice","className":"ModuleScript","filePaths":["src\\Array\\slice.lua"]},{"name":"some","className":"ModuleScript","filePaths":["src\\Array\\some.lua"]},{"name":"sort","className":"ModuleScript","filePaths":["src\\Array\\sort.lua"]},{"name":"splice","className":"ModuleScript","filePaths":["src\\Array\\splice.lua"]},{"name":"toSet","className":"ModuleScript","filePaths":["src\\Array\\toSet.lua"]},{"name":"unshift","className":"ModuleScript","filePaths":["src\\Array\\unshift.lua"]},{"name":"update","className":"ModuleScript","filePaths":["src\\Array\\update.lua"]},{"name":"zip","className":"ModuleScript","filePaths":["src\\Array\\zip.lua"]},{"name":"zipAll","className":"ModuleScript","filePaths":["src\\Array\\zipAll.lua"]}]},{"name":"Dictionary","className":"ModuleScript","filePaths":["src\\Dictionary\\init.lua"],"children":[{"name":"copy","className":"ModuleScript","filePaths":["src\\Dictionary\\copy.lua"]},{"name":"copyDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\copyDeep.lua"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Dictionary\\count.lua"]},{"name":"entries","className":"ModuleScript","filePaths":["src\\Dictionary\\entries.lua"]},{"name":"equals","className":"ModuleScript","filePaths":["src\\Dictionary\\equals.lua"]},{"name":"equalsDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\equalsDeep.lua"]},{"name":"every","className":"ModuleScript","filePaths":["src\\Dictionary\\every.lua"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Dictionary\\filter.lua"]},{"name":"flatten","className":"ModuleScript","filePaths":["src\\Dictionary\\flatten.lua"]},{"name":"flip","className":"ModuleScript","filePaths":["src\\Dictionary\\flip.lua"]},{"name":"freeze","className":"ModuleScript","filePaths":["src\\Dictionary\\freeze.lua"]},{"name":"freezeDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\freezeDeep.lua"]},{"name":"fromArrays","className":"ModuleScript","filePaths":["src\\Dictionary\\fromArrays.lua"]},{"name":"fromEntries","className":"ModuleScript","filePaths":["src\\Dictionary\\fromEntries.lua"]},{"name":"has","className":"ModuleScript","filePaths":["src\\Dictionary\\has.lua"]},{"name":"includes","className":"ModuleScript","filePaths":["src\\Dictionary\\includes.lua"]},{"name":"keys","className":"ModuleScript","filePaths":["src\\Dictionary\\keys.lua"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Dictionary\\map.lua"]},{"name":"merge","className":"ModuleScript","filePaths":["src\\Dictionary\\merge.lua"]},{"name":"mergeDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\mergeDeep.lua"]},{"name":"removeKey","className":"ModuleScript","filePaths":["src\\Dictionary\\removeKey.lua"]},{"name":"removeKeys","className":"ModuleScript","filePaths":["src\\Dictionary\\removeKeys.lua"]},{"name":"removeValue","className":"ModuleScript","filePaths":["src\\Dictionary\\removeValue.lua"]},{"name":"removeValues","className":"ModuleScript","filePaths":["src\\Dictionary\\removeValues.lua"]},{"name":"set","className":"ModuleScript","filePaths":["src\\Dictionary\\set.lua"]},{"name":"some","className":"ModuleScript","filePaths":["src\\Dictionary\\some.lua"]},{"name":"update","className":"ModuleScript","filePaths":["src\\Dictionary\\update.lua"]},{"name":"values","className":"ModuleScript","filePaths":["src\\Dictionary\\values.lua"]},{"name":"withKeys","className":"ModuleScript","filePaths":["src\\Dictionary\\withKeys.lua"]}]},{"name":"None","className":"ModuleScript","filePaths":["src\\None.lua"]},{"name":"Set","className":"ModuleScript","filePaths":["src\\Set\\init.lua"],"children":[{"name":"add","className":"ModuleScript","filePaths":["src\\Set\\add.lua"]},{"name":"copy","className":"ModuleScript","filePaths":["src\\Set\\copy.lua"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Set\\count.lua"]},{"name":"delete","className":"ModuleScript","filePaths":["src\\Set\\delete.lua"]},{"name":"difference","className":"ModuleScript","filePaths":["src\\Set\\difference.lua"]},{"name":"differenceSymmetric","className":"ModuleScript","filePaths":["src\\Set\\differenceSymmetric.lua"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Set\\filter.lua"]},{"name":"fromArray","className":"ModuleScript","filePaths":["src\\Set\\fromArray.lua"]},{"name":"has","className":"ModuleScript","filePaths":["src\\Set\\has.lua"]},{"name":"intersection","className":"ModuleScript","filePaths":["src\\Set\\intersection.lua"]},{"name":"isSubset","className":"ModuleScript","filePaths":["src\\Set\\isSubset.lua"]},{"name":"isSuperset","className":"ModuleScript","filePaths":["src\\Set\\isSuperset.lua"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Set\\map.lua"]},{"name":"merge","className":"ModuleScript","filePaths":["src\\Set\\merge.lua"]},{"name":"toArray","className":"ModuleScript","filePaths":["src\\Set\\toArray.lua"]}]},{"name":"Types","className":"ModuleScript","filePaths":["src\\Types.lua"]},{"name":"Util","className":"ModuleScript","filePaths":["src\\Util\\init.lua"],"children":[{"name":"equalObjects","className":"ModuleScript","filePaths":["src\\Util\\equalObjects.lua"]},{"name":"func","className":"ModuleScript","filePaths":["src\\Util\\func.lua"]},{"name":"isEmpty","className":"ModuleScript","filePaths":["src\\Util\\isEmpty.lua"]}]},{"name":"Metadata","className":"ModuleScript","filePaths":["wally.toml"]}]}
\ No newline at end of file
+{"name":"Sift","className":"ModuleScript","filePaths":["src\\init.luau","default.project.json"],"children":[{"name":"Array","className":"ModuleScript","filePaths":["src\\Array\\init.luau"],"children":[{"name":"concatDeep","className":"ModuleScript","filePaths":["src\\Array\\concatDeep.luau"]},{"name":"copy","className":"ModuleScript","filePaths":["src\\Array\\copy.luau"]},{"name":"copyDeep","className":"ModuleScript","filePaths":["src\\Array\\copyDeep.luau"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Array\\count.luau"]},{"name":"create","className":"ModuleScript","filePaths":["src\\Array\\create.luau"]},{"name":"difference","className":"ModuleScript","filePaths":["src\\Array\\difference.luau"]},{"name":"differenceSymmetric","className":"ModuleScript","filePaths":["src\\Array\\differenceSymmetric.luau"]},{"name":"equals","className":"ModuleScript","filePaths":["src\\Array\\equals.luau"]},{"name":"equalsDeep","className":"ModuleScript","filePaths":["src\\Array\\equalsDeep.luau"]},{"name":"every","className":"ModuleScript","filePaths":["src\\Array\\every.luau"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Array\\filter.luau"]},{"name":"find","className":"ModuleScript","filePaths":["src\\Array\\find.luau"]},{"name":"findLast","className":"ModuleScript","filePaths":["src\\Array\\findLast.luau"]},{"name":"findWhere","className":"ModuleScript","filePaths":["src\\Array\\findWhere.luau"]},{"name":"findWhereLast","className":"ModuleScript","filePaths":["src\\Array\\findWhereLast.luau"]},{"name":"first","className":"ModuleScript","filePaths":["src\\Array\\first.luau"]},{"name":"flatten","className":"ModuleScript","filePaths":["src\\Array\\flatten.luau"]},{"name":"freeze","className":"ModuleScript","filePaths":["src\\Array\\freeze.luau"]},{"name":"freezeDeep","className":"ModuleScript","filePaths":["src\\Array\\freezeDeep.luau"]},{"name":"includes","className":"ModuleScript","filePaths":["src\\Array\\includes.luau"]},{"name":"insert","className":"ModuleScript","filePaths":["src\\Array\\insert.luau"]},{"name":"is","className":"ModuleScript","filePaths":["src\\Array\\is.luau"]},{"name":"last","className":"ModuleScript","filePaths":["src\\Array\\last.luau"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Array\\map.luau"]},{"name":"pop","className":"ModuleScript","filePaths":["src\\Array\\pop.luau"]},{"name":"push","className":"ModuleScript","filePaths":["src\\Array\\push.luau"]},{"name":"reduce","className":"ModuleScript","filePaths":["src\\Array\\reduce.luau"]},{"name":"reduceRight","className":"ModuleScript","filePaths":["src\\Array\\reduceRight.luau"]},{"name":"removeIndex","className":"ModuleScript","filePaths":["src\\Array\\removeIndex.luau"]},{"name":"removeValues","className":"ModuleScript","filePaths":["src\\Array\\removeValues.luau"]},{"name":"reverse","className":"ModuleScript","filePaths":["src\\Array\\reverse.luau"]},{"name":"slice","className":"ModuleScript","filePaths":["src\\Array\\slice.luau"]},{"name":"update","className":"ModuleScript","filePaths":["src\\Array\\update.luau"]},{"name":"zip","className":"ModuleScript","filePaths":["src\\Array\\zip.luau"]},{"name":"zipAll","className":"ModuleScript","filePaths":["src\\Array\\zipAll.luau"]},{"name":"at","className":"ModuleScript","filePaths":["src\\Array\\at.luau"]},{"name":"concat","className":"ModuleScript","filePaths":["src\\Array\\concat.luau"]},{"name":"removeIndices","className":"ModuleScript","filePaths":["src\\Array\\removeIndices.luau"]},{"name":"removeValue","className":"ModuleScript","filePaths":["src\\Array\\removeValue.luau"]},{"name":"set","className":"ModuleScript","filePaths":["src\\Array\\set.luau"]},{"name":"shift","className":"ModuleScript","filePaths":["src\\Array\\shift.luau"]},{"name":"shuffle","className":"ModuleScript","filePaths":["src\\Array\\shuffle.luau"]},{"name":"some","className":"ModuleScript","filePaths":["src\\Array\\some.luau"]},{"name":"sort","className":"ModuleScript","filePaths":["src\\Array\\sort.luau"]},{"name":"splice","className":"ModuleScript","filePaths":["src\\Array\\splice.luau"]},{"name":"toSet","className":"ModuleScript","filePaths":["src\\Array\\toSet.luau"]},{"name":"unshift","className":"ModuleScript","filePaths":["src\\Array\\unshift.luau"]}]},{"name":"Dictionary","className":"ModuleScript","filePaths":["src\\Dictionary\\init.luau"],"children":[{"name":"copyDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\copyDeep.luau"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Dictionary\\count.luau"]},{"name":"entries","className":"ModuleScript","filePaths":["src\\Dictionary\\entries.luau"]},{"name":"equals","className":"ModuleScript","filePaths":["src\\Dictionary\\equals.luau"]},{"name":"equalsDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\equalsDeep.luau"]},{"name":"every","className":"ModuleScript","filePaths":["src\\Dictionary\\every.luau"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Dictionary\\filter.luau"]},{"name":"flatten","className":"ModuleScript","filePaths":["src\\Dictionary\\flatten.luau"]},{"name":"flip","className":"ModuleScript","filePaths":["src\\Dictionary\\flip.luau"]},{"name":"freeze","className":"ModuleScript","filePaths":["src\\Dictionary\\freeze.luau"]},{"name":"freezeDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\freezeDeep.luau"]},{"name":"fromArrays","className":"ModuleScript","filePaths":["src\\Dictionary\\fromArrays.luau"]},{"name":"fromEntries","className":"ModuleScript","filePaths":["src\\Dictionary\\fromEntries.luau"]},{"name":"has","className":"ModuleScript","filePaths":["src\\Dictionary\\has.luau"]},{"name":"includes","className":"ModuleScript","filePaths":["src\\Dictionary\\includes.luau"]},{"name":"keys","className":"ModuleScript","filePaths":["src\\Dictionary\\keys.luau"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Dictionary\\map.luau"]},{"name":"merge","className":"ModuleScript","filePaths":["src\\Dictionary\\merge.luau"]},{"name":"mergeDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\mergeDeep.luau"]},{"name":"removeKey","className":"ModuleScript","filePaths":["src\\Dictionary\\removeKey.luau"]},{"name":"removeKeys","className":"ModuleScript","filePaths":["src\\Dictionary\\removeKeys.luau"]},{"name":"removeValue","className":"ModuleScript","filePaths":["src\\Dictionary\\removeValue.luau"]},{"name":"removeValues","className":"ModuleScript","filePaths":["src\\Dictionary\\removeValues.luau"]},{"name":"set","className":"ModuleScript","filePaths":["src\\Dictionary\\set.luau"]},{"name":"some","className":"ModuleScript","filePaths":["src\\Dictionary\\some.luau"]},{"name":"update","className":"ModuleScript","filePaths":["src\\Dictionary\\update.luau"]},{"name":"values","className":"ModuleScript","filePaths":["src\\Dictionary\\values.luau"]},{"name":"withKeys","className":"ModuleScript","filePaths":["src\\Dictionary\\withKeys.luau"]},{"name":"copy","className":"ModuleScript","filePaths":["src\\Dictionary\\copy.luau"]}]},{"name":"Set","className":"ModuleScript","filePaths":["src\\Set\\init.luau"],"children":[{"name":"add","className":"ModuleScript","filePaths":["src\\Set\\add.luau"]},{"name":"copy","className":"ModuleScript","filePaths":["src\\Set\\copy.luau"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Set\\count.luau"]},{"name":"delete","className":"ModuleScript","filePaths":["src\\Set\\delete.luau"]},{"name":"difference","className":"ModuleScript","filePaths":["src\\Set\\difference.luau"]},{"name":"differenceSymmetric","className":"ModuleScript","filePaths":["src\\Set\\differenceSymmetric.luau"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Set\\filter.luau"]},{"name":"fromArray","className":"ModuleScript","filePaths":["src\\Set\\fromArray.luau"]},{"name":"has","className":"ModuleScript","filePaths":["src\\Set\\has.luau"]},{"name":"intersection","className":"ModuleScript","filePaths":["src\\Set\\intersection.luau"]},{"name":"isSubset","className":"ModuleScript","filePaths":["src\\Set\\isSubset.luau"]},{"name":"isSuperset","className":"ModuleScript","filePaths":["src\\Set\\isSuperset.luau"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Set\\map.luau"]},{"name":"merge","className":"ModuleScript","filePaths":["src\\Set\\merge.luau"]},{"name":"toArray","className":"ModuleScript","filePaths":["src\\Set\\toArray.luau"]}]},{"name":"Util","className":"ModuleScript","filePaths":["src\\Util\\init.luau"],"children":[{"name":"equalObjects","className":"ModuleScript","filePaths":["src\\Util\\equalObjects.luau"]},{"name":"func","className":"ModuleScript","filePaths":["src\\Util\\func.luau"]},{"name":"isEmpty","className":"ModuleScript","filePaths":["src\\Util\\isEmpty.luau"]}]},{"name":"Types","className":"ModuleScript","filePaths":["src\\Types.luau"]},{"name":"None","className":"ModuleScript","filePaths":["src\\None.luau"]}]}
\ No newline at end of file
diff --git a/src/Array/at.lua b/src/Array/at.luau
similarity index 100%
rename from src/Array/at.lua
rename to src/Array/at.luau
diff --git a/src/Array/concat.lua b/src/Array/concat.luau
similarity index 100%
rename from src/Array/concat.lua
rename to src/Array/concat.luau
diff --git a/src/Array/concatDeep.lua b/src/Array/concatDeep.luau
similarity index 100%
rename from src/Array/concatDeep.lua
rename to src/Array/concatDeep.luau
diff --git a/src/Array/copy.lua b/src/Array/copy.luau
similarity index 100%
rename from src/Array/copy.lua
rename to src/Array/copy.luau
diff --git a/src/Array/copyDeep.lua b/src/Array/copyDeep.luau
similarity index 100%
rename from src/Array/copyDeep.lua
rename to src/Array/copyDeep.luau
diff --git a/src/Array/count.lua b/src/Array/count.luau
similarity index 100%
rename from src/Array/count.lua
rename to src/Array/count.luau
diff --git a/src/Array/create.lua b/src/Array/create.luau
similarity index 100%
rename from src/Array/create.lua
rename to src/Array/create.luau
diff --git a/src/Array/difference.lua b/src/Array/difference.luau
similarity index 100%
rename from src/Array/difference.lua
rename to src/Array/difference.luau
diff --git a/src/Array/differenceSymmetric.lua b/src/Array/differenceSymmetric.luau
similarity index 100%
rename from src/Array/differenceSymmetric.lua
rename to src/Array/differenceSymmetric.luau
diff --git a/src/Array/equals.lua b/src/Array/equals.luau
similarity index 100%
rename from src/Array/equals.lua
rename to src/Array/equals.luau
diff --git a/src/Array/equalsDeep.lua b/src/Array/equalsDeep.luau
similarity index 100%
rename from src/Array/equalsDeep.lua
rename to src/Array/equalsDeep.luau
diff --git a/src/Array/every.lua b/src/Array/every.luau
similarity index 100%
rename from src/Array/every.lua
rename to src/Array/every.luau
diff --git a/src/Array/filter.lua b/src/Array/filter.luau
similarity index 100%
rename from src/Array/filter.lua
rename to src/Array/filter.luau
diff --git a/src/Array/find.lua b/src/Array/find.luau
similarity index 100%
rename from src/Array/find.lua
rename to src/Array/find.luau
diff --git a/src/Array/findLast.lua b/src/Array/findLast.luau
similarity index 100%
rename from src/Array/findLast.lua
rename to src/Array/findLast.luau
diff --git a/src/Array/findWhere.lua b/src/Array/findWhere.luau
similarity index 100%
rename from src/Array/findWhere.lua
rename to src/Array/findWhere.luau
diff --git a/src/Array/findWhereLast.lua b/src/Array/findWhereLast.luau
similarity index 100%
rename from src/Array/findWhereLast.lua
rename to src/Array/findWhereLast.luau
diff --git a/src/Array/first.lua b/src/Array/first.luau
similarity index 100%
rename from src/Array/first.lua
rename to src/Array/first.luau
diff --git a/src/Array/flatten.lua b/src/Array/flatten.luau
similarity index 100%
rename from src/Array/flatten.lua
rename to src/Array/flatten.luau
diff --git a/src/Array/freeze.lua b/src/Array/freeze.luau
similarity index 100%
rename from src/Array/freeze.lua
rename to src/Array/freeze.luau
diff --git a/src/Array/freezeDeep.lua b/src/Array/freezeDeep.luau
similarity index 100%
rename from src/Array/freezeDeep.lua
rename to src/Array/freezeDeep.luau
diff --git a/src/Array/includes.lua b/src/Array/includes.luau
similarity index 100%
rename from src/Array/includes.lua
rename to src/Array/includes.luau
diff --git a/src/Array/init.lua b/src/Array/init.luau
similarity index 100%
rename from src/Array/init.lua
rename to src/Array/init.luau
diff --git a/src/Array/insert.lua b/src/Array/insert.luau
similarity index 100%
rename from src/Array/insert.lua
rename to src/Array/insert.luau
diff --git a/src/Array/is.lua b/src/Array/is.luau
similarity index 100%
rename from src/Array/is.lua
rename to src/Array/is.luau
diff --git a/src/Array/last.lua b/src/Array/last.luau
similarity index 100%
rename from src/Array/last.lua
rename to src/Array/last.luau
diff --git a/src/Array/map.lua b/src/Array/map.luau
similarity index 100%
rename from src/Array/map.lua
rename to src/Array/map.luau
diff --git a/src/Array/pop.lua b/src/Array/pop.luau
similarity index 100%
rename from src/Array/pop.lua
rename to src/Array/pop.luau
diff --git a/src/Array/push.lua b/src/Array/push.luau
similarity index 100%
rename from src/Array/push.lua
rename to src/Array/push.luau
diff --git a/src/Array/reduce.lua b/src/Array/reduce.luau
similarity index 100%
rename from src/Array/reduce.lua
rename to src/Array/reduce.luau
diff --git a/src/Array/reduceRight.lua b/src/Array/reduceRight.luau
similarity index 100%
rename from src/Array/reduceRight.lua
rename to src/Array/reduceRight.luau
diff --git a/src/Array/removeIndex.lua b/src/Array/removeIndex.luau
similarity index 100%
rename from src/Array/removeIndex.lua
rename to src/Array/removeIndex.luau
diff --git a/src/Array/removeIndices.lua b/src/Array/removeIndices.luau
similarity index 100%
rename from src/Array/removeIndices.lua
rename to src/Array/removeIndices.luau
diff --git a/src/Array/removeValue.lua b/src/Array/removeValue.luau
similarity index 100%
rename from src/Array/removeValue.lua
rename to src/Array/removeValue.luau
diff --git a/src/Array/removeValues.lua b/src/Array/removeValues.luau
similarity index 100%
rename from src/Array/removeValues.lua
rename to src/Array/removeValues.luau
diff --git a/src/Array/reverse.lua b/src/Array/reverse.luau
similarity index 100%
rename from src/Array/reverse.lua
rename to src/Array/reverse.luau
diff --git a/src/Array/set.lua b/src/Array/set.luau
similarity index 100%
rename from src/Array/set.lua
rename to src/Array/set.luau
diff --git a/src/Array/shift.lua b/src/Array/shift.luau
similarity index 100%
rename from src/Array/shift.lua
rename to src/Array/shift.luau
diff --git a/src/Array/shuffle.lua b/src/Array/shuffle.luau
similarity index 100%
rename from src/Array/shuffle.lua
rename to src/Array/shuffle.luau
diff --git a/src/Array/slice.lua b/src/Array/slice.luau
similarity index 100%
rename from src/Array/slice.lua
rename to src/Array/slice.luau
diff --git a/src/Array/some.lua b/src/Array/some.luau
similarity index 100%
rename from src/Array/some.lua
rename to src/Array/some.luau
diff --git a/src/Array/sort.lua b/src/Array/sort.luau
similarity index 100%
rename from src/Array/sort.lua
rename to src/Array/sort.luau
diff --git a/src/Array/splice.lua b/src/Array/splice.luau
similarity index 100%
rename from src/Array/splice.lua
rename to src/Array/splice.luau
diff --git a/src/Array/toSet.lua b/src/Array/toSet.luau
similarity index 100%
rename from src/Array/toSet.lua
rename to src/Array/toSet.luau
diff --git a/src/Array/unshift.lua b/src/Array/unshift.luau
similarity index 100%
rename from src/Array/unshift.lua
rename to src/Array/unshift.luau
diff --git a/src/Array/update.lua b/src/Array/update.luau
similarity index 100%
rename from src/Array/update.lua
rename to src/Array/update.luau
diff --git a/src/Array/zip.lua b/src/Array/zip.luau
similarity index 100%
rename from src/Array/zip.lua
rename to src/Array/zip.luau
diff --git a/src/Array/zipAll.lua b/src/Array/zipAll.luau
similarity index 100%
rename from src/Array/zipAll.lua
rename to src/Array/zipAll.luau
diff --git a/src/Dictionary/copy.lua b/src/Dictionary/copy.luau
similarity index 100%
rename from src/Dictionary/copy.lua
rename to src/Dictionary/copy.luau
diff --git a/src/Dictionary/copyDeep.lua b/src/Dictionary/copyDeep.luau
similarity index 100%
rename from src/Dictionary/copyDeep.lua
rename to src/Dictionary/copyDeep.luau
diff --git a/src/Dictionary/count.lua b/src/Dictionary/count.luau
similarity index 100%
rename from src/Dictionary/count.lua
rename to src/Dictionary/count.luau
diff --git a/src/Dictionary/entries.lua b/src/Dictionary/entries.luau
similarity index 100%
rename from src/Dictionary/entries.lua
rename to src/Dictionary/entries.luau
diff --git a/src/Dictionary/equals.lua b/src/Dictionary/equals.luau
similarity index 100%
rename from src/Dictionary/equals.lua
rename to src/Dictionary/equals.luau
diff --git a/src/Dictionary/equalsDeep.lua b/src/Dictionary/equalsDeep.luau
similarity index 100%
rename from src/Dictionary/equalsDeep.lua
rename to src/Dictionary/equalsDeep.luau
diff --git a/src/Dictionary/every.lua b/src/Dictionary/every.luau
similarity index 100%
rename from src/Dictionary/every.lua
rename to src/Dictionary/every.luau
diff --git a/src/Dictionary/filter.lua b/src/Dictionary/filter.luau
similarity index 100%
rename from src/Dictionary/filter.lua
rename to src/Dictionary/filter.luau
diff --git a/src/Dictionary/flatten.lua b/src/Dictionary/flatten.luau
similarity index 100%
rename from src/Dictionary/flatten.lua
rename to src/Dictionary/flatten.luau
diff --git a/src/Dictionary/flip.lua b/src/Dictionary/flip.luau
similarity index 100%
rename from src/Dictionary/flip.lua
rename to src/Dictionary/flip.luau
diff --git a/src/Dictionary/freeze.lua b/src/Dictionary/freeze.luau
similarity index 100%
rename from src/Dictionary/freeze.lua
rename to src/Dictionary/freeze.luau
diff --git a/src/Dictionary/freezeDeep.lua b/src/Dictionary/freezeDeep.luau
similarity index 100%
rename from src/Dictionary/freezeDeep.lua
rename to src/Dictionary/freezeDeep.luau
diff --git a/src/Dictionary/fromArrays.lua b/src/Dictionary/fromArrays.luau
similarity index 100%
rename from src/Dictionary/fromArrays.lua
rename to src/Dictionary/fromArrays.luau
diff --git a/src/Dictionary/fromEntries.lua b/src/Dictionary/fromEntries.luau
similarity index 100%
rename from src/Dictionary/fromEntries.lua
rename to src/Dictionary/fromEntries.luau
diff --git a/src/Dictionary/has.lua b/src/Dictionary/has.luau
similarity index 100%
rename from src/Dictionary/has.lua
rename to src/Dictionary/has.luau
diff --git a/src/Dictionary/includes.lua b/src/Dictionary/includes.luau
similarity index 100%
rename from src/Dictionary/includes.lua
rename to src/Dictionary/includes.luau
diff --git a/src/Dictionary/init.lua b/src/Dictionary/init.luau
similarity index 100%
rename from src/Dictionary/init.lua
rename to src/Dictionary/init.luau
diff --git a/src/Dictionary/keys.lua b/src/Dictionary/keys.luau
similarity index 100%
rename from src/Dictionary/keys.lua
rename to src/Dictionary/keys.luau
diff --git a/src/Dictionary/map.lua b/src/Dictionary/map.luau
similarity index 100%
rename from src/Dictionary/map.lua
rename to src/Dictionary/map.luau
diff --git a/src/Dictionary/merge.lua b/src/Dictionary/merge.luau
similarity index 100%
rename from src/Dictionary/merge.lua
rename to src/Dictionary/merge.luau
diff --git a/src/Dictionary/mergeDeep.lua b/src/Dictionary/mergeDeep.luau
similarity index 100%
rename from src/Dictionary/mergeDeep.lua
rename to src/Dictionary/mergeDeep.luau
diff --git a/src/Dictionary/removeKey.lua b/src/Dictionary/removeKey.luau
similarity index 100%
rename from src/Dictionary/removeKey.lua
rename to src/Dictionary/removeKey.luau
diff --git a/src/Dictionary/removeKeys.lua b/src/Dictionary/removeKeys.luau
similarity index 100%
rename from src/Dictionary/removeKeys.lua
rename to src/Dictionary/removeKeys.luau
diff --git a/src/Dictionary/removeValue.lua b/src/Dictionary/removeValue.luau
similarity index 100%
rename from src/Dictionary/removeValue.lua
rename to src/Dictionary/removeValue.luau
diff --git a/src/Dictionary/removeValues.lua b/src/Dictionary/removeValues.luau
similarity index 100%
rename from src/Dictionary/removeValues.lua
rename to src/Dictionary/removeValues.luau
diff --git a/src/Dictionary/set.lua b/src/Dictionary/set.luau
similarity index 100%
rename from src/Dictionary/set.lua
rename to src/Dictionary/set.luau
diff --git a/src/Dictionary/some.lua b/src/Dictionary/some.luau
similarity index 100%
rename from src/Dictionary/some.lua
rename to src/Dictionary/some.luau
diff --git a/src/Dictionary/update.lua b/src/Dictionary/update.luau
similarity index 100%
rename from src/Dictionary/update.lua
rename to src/Dictionary/update.luau
diff --git a/src/Dictionary/values.lua b/src/Dictionary/values.luau
similarity index 100%
rename from src/Dictionary/values.lua
rename to src/Dictionary/values.luau
diff --git a/src/Dictionary/withKeys.lua b/src/Dictionary/withKeys.luau
similarity index 100%
rename from src/Dictionary/withKeys.lua
rename to src/Dictionary/withKeys.luau
diff --git a/src/None.lua b/src/None.luau
similarity index 100%
rename from src/None.lua
rename to src/None.luau
diff --git a/src/Set/add.lua b/src/Set/add.luau
similarity index 100%
rename from src/Set/add.lua
rename to src/Set/add.luau
diff --git a/src/Set/copy.lua b/src/Set/copy.luau
similarity index 100%
rename from src/Set/copy.lua
rename to src/Set/copy.luau
diff --git a/src/Set/count.lua b/src/Set/count.luau
similarity index 100%
rename from src/Set/count.lua
rename to src/Set/count.luau
diff --git a/src/Set/delete.lua b/src/Set/delete.luau
similarity index 100%
rename from src/Set/delete.lua
rename to src/Set/delete.luau
diff --git a/src/Set/difference.lua b/src/Set/difference.luau
similarity index 100%
rename from src/Set/difference.lua
rename to src/Set/difference.luau
diff --git a/src/Set/differenceSymmetric.lua b/src/Set/differenceSymmetric.luau
similarity index 100%
rename from src/Set/differenceSymmetric.lua
rename to src/Set/differenceSymmetric.luau
diff --git a/src/Set/filter.lua b/src/Set/filter.luau
similarity index 100%
rename from src/Set/filter.lua
rename to src/Set/filter.luau
diff --git a/src/Set/fromArray.lua b/src/Set/fromArray.luau
similarity index 100%
rename from src/Set/fromArray.lua
rename to src/Set/fromArray.luau
diff --git a/src/Set/has.lua b/src/Set/has.luau
similarity index 100%
rename from src/Set/has.lua
rename to src/Set/has.luau
diff --git a/src/Set/init.lua b/src/Set/init.luau
similarity index 100%
rename from src/Set/init.lua
rename to src/Set/init.luau
diff --git a/src/Set/intersection.lua b/src/Set/intersection.luau
similarity index 100%
rename from src/Set/intersection.lua
rename to src/Set/intersection.luau
diff --git a/src/Set/isSubset.lua b/src/Set/isSubset.luau
similarity index 100%
rename from src/Set/isSubset.lua
rename to src/Set/isSubset.luau
diff --git a/src/Set/isSuperset.lua b/src/Set/isSuperset.luau
similarity index 100%
rename from src/Set/isSuperset.lua
rename to src/Set/isSuperset.luau
diff --git a/src/Set/map.lua b/src/Set/map.luau
similarity index 100%
rename from src/Set/map.lua
rename to src/Set/map.luau
diff --git a/src/Set/merge.lua b/src/Set/merge.luau
similarity index 100%
rename from src/Set/merge.lua
rename to src/Set/merge.luau
diff --git a/src/Set/toArray.lua b/src/Set/toArray.luau
similarity index 100%
rename from src/Set/toArray.lua
rename to src/Set/toArray.luau
diff --git a/src/Types.lua b/src/Types.luau
similarity index 100%
rename from src/Types.lua
rename to src/Types.luau
diff --git a/src/Util/equalObjects.lua b/src/Util/equalObjects.luau
similarity index 100%
rename from src/Util/equalObjects.lua
rename to src/Util/equalObjects.luau
diff --git a/src/Util/func.lua b/src/Util/func.luau
similarity index 100%
rename from src/Util/func.lua
rename to src/Util/func.luau
diff --git a/src/Util/init.lua b/src/Util/init.luau
similarity index 100%
rename from src/Util/init.lua
rename to src/Util/init.luau
diff --git a/src/Util/isEmpty.lua b/src/Util/isEmpty.luau
similarity index 100%
rename from src/Util/isEmpty.lua
rename to src/Util/isEmpty.luau
diff --git a/src/init.lua b/src/init.luau
similarity index 100%
rename from src/init.lua
rename to src/init.luau
From 922bcdd9af0d6c3e9b275e193f749883a0039bbe Mon Sep 17 00:00:00 2001
From: Cam <21029087+cxmeel@users.noreply.github.com>
Date: Tue, 12 Mar 2024 12:43:14 +0000
Subject: [PATCH 05/43] Luau rewrite
---
.gitignore | 1 +
.luaurc | 3 +-
.vscode/settings.json | 8 +-
@types/Array.d.ts | 187 ------------------------
@types/Dictionary.d.ts | 166 ---------------------
@types/Set.d.ts | 53 -------
@types/Util.d.ts | 49 -------
@types/index.d.ts | 19 ---
README.md | 25 ----
docs/Examples.md | 77 ----------
docs/Installation.md | 61 --------
package.json | 7 +-
sourcemap.json | 1 -
src/Array/at.luau | 29 ++--
src/Array/concat.luau | 47 ++----
src/Array/concatDeep.luau | 52 -------
src/Array/copy.luau | 22 +--
src/Array/copyDeep.luau | 33 ++---
src/Array/count.luau | 41 ++----
src/Array/create.luau | 28 ++--
src/Array/difference.luau | 42 ------
src/Array/difference.luau.todo | 1 +
src/Array/differenceSymmetric.luau | 42 ------
src/Array/differenceSymmetric.luau.todo | 1 +
src/Array/equals.luau | 51 +++----
src/Array/equalsDeep.luau | 51 +++----
src/Array/every.luau | 35 ++---
src/Array/filter.luau | 44 ++----
src/Array/find.luau | 37 ++---
src/Array/findLast.luau | 40 +++--
src/Array/findWhere.luau | 39 ++---
src/Array/findWhereLast.luau | 43 ++----
src/Array/first.luau | 21 +--
src/Array/flatten.luau | 57 ++++----
src/Array/freeze.luau | 31 ++--
src/Array/freezeDeep.luau | 40 ++---
src/Array/includes.luau | 32 +---
src/Array/init.luau | 82 +----------
src/Array/insert.luau | 55 +++----
src/Array/is.luau | 28 ++--
src/Array/last.luau | 21 +--
src/Array/map.luau | 38 ++---
src/Array/partition.luau | 30 ++++
src/Array/pop.luau | 37 +++--
src/Array/push.luau | 36 +----
src/Array/reduce.luau | 45 ++----
src/Array/reduceRight.luau | 46 ++----
src/Array/removeIndex.luau | 36 +----
src/Array/removeIndices.luau | 47 +++---
src/Array/removeValue.luau | 30 +---
src/Array/removeValues.luau | 40 ++---
src/Array/reverse.luau | 23 +--
src/Array/set.luau | 44 +++---
src/Array/shift.luau | 37 +++--
src/Array/shuffle.luau | 38 ++---
src/Array/slice.luau | 50 +++----
src/Array/some.luau | 35 ++---
src/Array/sort.luau | 30 ++--
src/Array/splice.luau | 58 ++++----
src/Array/toSet.luau | 32 ++--
src/Array/unshift.luau | 30 +---
src/Array/update.luau | 71 +++------
src/Array/zip.luau | 52 +++----
src/Array/zipAll.luau | 58 ++++----
src/Dictionary/copy.luau | 20 ---
src/Dictionary/copy.luau.todo | 0
src/Dictionary/copyDeep.luau | 32 ----
src/Dictionary/copyDeep.luau.todo | 0
src/Dictionary/count.luau | 42 ------
src/Dictionary/count.luau.todo | 0
src/Dictionary/entries.luau | 27 ----
src/Dictionary/entries.luau.todo | 0
src/Dictionary/equals.luau | 64 --------
src/Dictionary/equals.luau.todo | 0
src/Dictionary/equalsDeep.luau | 64 --------
src/Dictionary/equalsDeep.luau.todo | 0
src/Dictionary/every.luau | 37 -----
src/Dictionary/every.luau.todo | 0
src/Dictionary/filter.luau | 41 ------
src/Dictionary/filter.luau.todo | 0
src/Dictionary/flatten.luau | 52 -------
src/Dictionary/flatten.luau.todo | 0
src/Dictionary/flip.luau | 27 ----
src/Dictionary/flip.luau.todo | 0
src/Dictionary/freeze.luau | 31 ----
src/Dictionary/freeze.luau.todo | 0
src/Dictionary/freezeDeep.luau | 38 -----
src/Dictionary/freezeDeep.luau.todo | 0
src/Dictionary/fromArrays.luau | 31 ----
src/Dictionary/fromArrays.luau.todo | 0
src/Dictionary/fromEntries.luau | 27 ----
src/Dictionary/fromEntries.luau.todo | 0
src/Dictionary/has.luau | 25 ----
src/Dictionary/has.luau.todo | 0
src/Dictionary/includes.luau | 29 ----
src/Dictionary/includes.luau.todo | 0
src/Dictionary/init.luau | 51 +------
src/Dictionary/keys.luau | 27 ----
src/Dictionary/keys.luau.todo | 0
src/Dictionary/map.luau | 40 -----
src/Dictionary/map.luau.todo | 0
src/Dictionary/merge.luau | 45 ------
src/Dictionary/merge.luau.todo | 0
src/Dictionary/mergeDeep.luau | 56 -------
src/Dictionary/mergeDeep.luau.todo | 0
src/Dictionary/removeKey.luau | 29 ----
src/Dictionary/removeKey.luau.todo | 0
src/Dictionary/removeKeys.luau | 30 ----
src/Dictionary/removeKeys.luau.todo | 0
src/Dictionary/removeValue.luau | 31 ----
src/Dictionary/removeValue.luau.todo | 0
src/Dictionary/removeValues.luau | 36 -----
src/Dictionary/removeValues.luau.todo | 0
src/Dictionary/set.luau | 29 ----
src/Dictionary/set.luau.todo | 0
src/Dictionary/some.luau | 37 -----
src/Dictionary/some.luau.todo | 0
src/Dictionary/update.luau | 60 --------
src/Dictionary/update.luau.todo | 0
src/Dictionary/values.luau | 27 ----
src/Dictionary/values.luau.todo | 0
src/Dictionary/withKeys.luau | 29 ----
src/Dictionary/withKeys.luau.todo | 0
src/None.luau | 16 +-
src/Set/add.luau | 32 ----
src/Set/add.luau.todo | 0
src/Set/copy.luau | 21 ---
src/Set/copy.luau.todo | 0
src/Set/count.luau | 42 ------
src/Set/count.luau.todo | 0
src/Set/delete.luau | 34 -----
src/Set/delete.luau.todo | 0
src/Set/difference.luau | 37 -----
src/Set/difference.luau.todo | 0
src/Set/differenceSymmetric.luau | 41 ------
src/Set/differenceSymmetric.luau.todo | 0
src/Set/filter.luau | 41 ------
src/Set/filter.luau.todo | 0
src/Set/fromArray.luau | 30 ----
src/Set/fromArray.luau.todo | 0
src/Set/has.luau | 22 ---
src/Set/has.luau.todo | 0
src/Set/init.luau | 38 +----
src/Set/intersection.luau | 46 ------
src/Set/intersection.luau.todo | 0
src/Set/isSubset.luau | 29 ----
src/Set/isSubset.luau.todo | 0
src/Set/isSuperset.luau | 25 ----
src/Set/isSuperset.luau.todo | 0
src/Set/map.luau | 34 -----
src/Set/map.luau.todo | 0
src/Set/merge.luau | 38 -----
src/Set/merge.luau.todo | 0
src/Set/toArray.luau | 27 ----
src/Set/toArray.luau.todo | 0
src/Types.luau | 13 +-
src/Util.luau | 36 +++++
src/Util/equalObjects.luau | 32 ----
src/Util/func.luau | 15 --
src/Util/init.luau | 5 -
src/Util/isEmpty.luau | 26 ----
src/init.luau | 56 ++-----
test.project.json | 33 -----
wally.toml | 2 +-
164 files changed, 747 insertions(+), 3783 deletions(-)
delete mode 100644 @types/Array.d.ts
delete mode 100644 @types/Dictionary.d.ts
delete mode 100644 @types/Set.d.ts
delete mode 100644 @types/Util.d.ts
delete mode 100644 @types/index.d.ts
delete mode 100644 docs/Examples.md
delete mode 100644 docs/Installation.md
delete mode 100644 sourcemap.json
delete mode 100644 src/Array/concatDeep.luau
delete mode 100644 src/Array/difference.luau
create mode 100644 src/Array/difference.luau.todo
delete mode 100644 src/Array/differenceSymmetric.luau
create mode 100644 src/Array/differenceSymmetric.luau.todo
create mode 100644 src/Array/partition.luau
delete mode 100644 src/Dictionary/copy.luau
create mode 100644 src/Dictionary/copy.luau.todo
delete mode 100644 src/Dictionary/copyDeep.luau
create mode 100644 src/Dictionary/copyDeep.luau.todo
delete mode 100644 src/Dictionary/count.luau
create mode 100644 src/Dictionary/count.luau.todo
delete mode 100644 src/Dictionary/entries.luau
create mode 100644 src/Dictionary/entries.luau.todo
delete mode 100644 src/Dictionary/equals.luau
create mode 100644 src/Dictionary/equals.luau.todo
delete mode 100644 src/Dictionary/equalsDeep.luau
create mode 100644 src/Dictionary/equalsDeep.luau.todo
delete mode 100644 src/Dictionary/every.luau
create mode 100644 src/Dictionary/every.luau.todo
delete mode 100644 src/Dictionary/filter.luau
create mode 100644 src/Dictionary/filter.luau.todo
delete mode 100644 src/Dictionary/flatten.luau
create mode 100644 src/Dictionary/flatten.luau.todo
delete mode 100644 src/Dictionary/flip.luau
create mode 100644 src/Dictionary/flip.luau.todo
delete mode 100644 src/Dictionary/freeze.luau
create mode 100644 src/Dictionary/freeze.luau.todo
delete mode 100644 src/Dictionary/freezeDeep.luau
create mode 100644 src/Dictionary/freezeDeep.luau.todo
delete mode 100644 src/Dictionary/fromArrays.luau
create mode 100644 src/Dictionary/fromArrays.luau.todo
delete mode 100644 src/Dictionary/fromEntries.luau
create mode 100644 src/Dictionary/fromEntries.luau.todo
delete mode 100644 src/Dictionary/has.luau
create mode 100644 src/Dictionary/has.luau.todo
delete mode 100644 src/Dictionary/includes.luau
create mode 100644 src/Dictionary/includes.luau.todo
delete mode 100644 src/Dictionary/keys.luau
create mode 100644 src/Dictionary/keys.luau.todo
delete mode 100644 src/Dictionary/map.luau
create mode 100644 src/Dictionary/map.luau.todo
delete mode 100644 src/Dictionary/merge.luau
create mode 100644 src/Dictionary/merge.luau.todo
delete mode 100644 src/Dictionary/mergeDeep.luau
create mode 100644 src/Dictionary/mergeDeep.luau.todo
delete mode 100644 src/Dictionary/removeKey.luau
create mode 100644 src/Dictionary/removeKey.luau.todo
delete mode 100644 src/Dictionary/removeKeys.luau
create mode 100644 src/Dictionary/removeKeys.luau.todo
delete mode 100644 src/Dictionary/removeValue.luau
create mode 100644 src/Dictionary/removeValue.luau.todo
delete mode 100644 src/Dictionary/removeValues.luau
create mode 100644 src/Dictionary/removeValues.luau.todo
delete mode 100644 src/Dictionary/set.luau
create mode 100644 src/Dictionary/set.luau.todo
delete mode 100644 src/Dictionary/some.luau
create mode 100644 src/Dictionary/some.luau.todo
delete mode 100644 src/Dictionary/update.luau
create mode 100644 src/Dictionary/update.luau.todo
delete mode 100644 src/Dictionary/values.luau
create mode 100644 src/Dictionary/values.luau.todo
delete mode 100644 src/Dictionary/withKeys.luau
create mode 100644 src/Dictionary/withKeys.luau.todo
delete mode 100644 src/Set/add.luau
create mode 100644 src/Set/add.luau.todo
delete mode 100644 src/Set/copy.luau
create mode 100644 src/Set/copy.luau.todo
delete mode 100644 src/Set/count.luau
create mode 100644 src/Set/count.luau.todo
delete mode 100644 src/Set/delete.luau
create mode 100644 src/Set/delete.luau.todo
delete mode 100644 src/Set/difference.luau
create mode 100644 src/Set/difference.luau.todo
delete mode 100644 src/Set/differenceSymmetric.luau
create mode 100644 src/Set/differenceSymmetric.luau.todo
delete mode 100644 src/Set/filter.luau
create mode 100644 src/Set/filter.luau.todo
delete mode 100644 src/Set/fromArray.luau
create mode 100644 src/Set/fromArray.luau.todo
delete mode 100644 src/Set/has.luau
create mode 100644 src/Set/has.luau.todo
delete mode 100644 src/Set/intersection.luau
create mode 100644 src/Set/intersection.luau.todo
delete mode 100644 src/Set/isSubset.luau
create mode 100644 src/Set/isSubset.luau.todo
delete mode 100644 src/Set/isSuperset.luau
create mode 100644 src/Set/isSuperset.luau.todo
delete mode 100644 src/Set/map.luau
create mode 100644 src/Set/map.luau.todo
delete mode 100644 src/Set/merge.luau
create mode 100644 src/Set/merge.luau.todo
delete mode 100644 src/Set/toArray.luau
create mode 100644 src/Set/toArray.luau.todo
create mode 100644 src/Util.luau
delete mode 100644 src/Util/equalObjects.luau
delete mode 100644 src/Util/func.luau
delete mode 100644 src/Util/init.luau
delete mode 100644 src/Util/isEmpty.luau
delete mode 100644 test.project.json
diff --git a/.gitignore b/.gitignore
index f0deb4d..77b402b 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,6 +2,7 @@
.env
.env.*
*.tsbuildinfo
+sourcemap.json
/Packages
/DevPackages
diff --git a/.luaurc b/.luaurc
index cfbdb52..06b85fb 100644
--- a/.luaurc
+++ b/.luaurc
@@ -3,6 +3,7 @@
"lint": { "*": false },
"aliases": {
"Pkg": "Packages",
- "DevPkg": "DevPackages"
+ "DevPkg": "DevPackages",
+ "Sift": "src"
}
}
diff --git a/.vscode/settings.json b/.vscode/settings.json
index 1acaf69..5a1a07f 100644
--- a/.vscode/settings.json
+++ b/.vscode/settings.json
@@ -14,6 +14,10 @@
},
"luau-lsp.require.directoryAliases": {
"@Pkg": "Packages",
- "@DevPkg": "DevPackages"
- }
+ "@DevPkg": "DevPackages",
+ "@Sift": "src"
+ },
+ "luau-lsp.types.roblox": false,
+ "luau-lsp.require.mode": "relativeToFile",
+ "luau-lsp.completion.imports.suggestRequires": false
}
diff --git a/@types/Array.d.ts b/@types/Array.d.ts
deleted file mode 100644
index 6ef8f70..0000000
--- a/@types/Array.d.ts
+++ /dev/null
@@ -1,187 +0,0 @@
-import type { ReadonlyDeep, ReplaceType, SiftNone } from "./Util"
-
-declare namespace SiftArray {
- export function at(
- array: V[],
- index: number
- ): V | undefined
-
- export function concat(...arrays: T[]): T
-
- export function concatDeep(...arrays: T[]): T
-
- export function copy(array: T): T
-
- export function copyDeep(array: T): T
-
- export function count(
- array: T[],
- predicate: (value: T, index: number, array: Readonly) => unknown
- ): number
-
- export function create(length: number, value?: T): T[]
-
- export function difference(array: T[], ...values: T[]): T[]
-
- export function differenceSymmetric(array: T[], ...values: T[]): T[]
-
- export function equals(...arrays: unknown[]): boolean
-
- export function equalsDeep(...arrays: unknown[]): boolean
-
- export function every(
- array: T[],
- predicate: (value: T, index: number, array: Readonly) => unknown
- ): boolean
-
- export function filter(
- array: T[],
- filterer?: (value: T, index: number, array: Readonly) => unknown
- ): T[]
-
- export function find(
- array: T[],
- value?: T,
- from?: number
- ): number | undefined
-
- export function findLast(
- array: T[],
- value?: T,
- from?: number
- ): number | undefined
-
- export function findWhere(
- array: T[],
- predicate: (value: T, index: number, array: Readonly) => unknown,
- from?: number
- ): number
-
- export function findWhereLast(
- array: T[],
- predicate: (value: T, index: number, array: Readonly) => unknown,
- from?: number
- ): number
-
- export function first(array: T[]): T
-
- export function flatten(array: T[], depth?: number): T[]
-
- export function freeze(array: T[]): Readonly
-
- export function freezeDeep(array: T[]): ReadonlyDeep
-
- export function includes(array: T[], value: T, from?: number): boolean
-
- export function insert(array: T[], index: number, ...values: T[]): T[]
-
- export function is(value: any): boolean
-
- export function last(array: T[]): T
-
- export function map(
- array: T[],
- mapper: (value: T, index: number, array: Readonly) => U
- ): U[]
-
- export function pop(array: T[], count?: number): T[]
-
- export function push(array: T[], ...values: T[]): T[]
-
- export function reduce(
- array: T[],
- reducer: (
- accumulator: U,
- value: T,
- index: number,
- array: Readonly
- ) => U,
- initialValue?: U
- ): U
-
- export function reduceRight(
- array: T[],
- reducer: (
- accumulator: U,
- value: T,
- index: number,
- array: Readonly
- ) => U,
- initialValue?: U
- ): U
-
- export function removeIndex(array: T[], index: number): T[]
-
- export function removeIndices(array: T[], ...indices: number[]): T[]
-
- export function removeValue(array: T[], value: T): T[]
-
- export function removeValues(array: T[], ...values: T[]): T[]
-
- export function reverse(array: T[]): T[]
-
- export function set(array: T[], index: number, value: T): T[]
-
- export function shift(array: T[], count?: number): T[]
-
- export function shuffle(array: T[]): T[]
-
- export function slice(array: T[], from?: number, to?: number): T[]
-
- export function some(
- array: T[],
- predicate: (value: T, index: number, array: Readonly) => unknown
- ): boolean
-
- export function sort(array: T[], comparator?: (a: T, b: T) => unknown): T[]
-
- export function splice(
- array: T[],
- start?: number,
- end?: number,
- ...values: T[]
- ): T[]
-
- export function toSet(array: T[]): Set
-
- export function unshift(array: T[], ...values: T[]): T[]
-
- export function update(
- array: T[],
- index: number,
- updater?: (value: T, index: number) => T,
- callback?: (index: number) => T
- ): T[]
-
- export function zip(
- ...arrays: T
- ): {
- [K in keyof T]: T[K] extends (infer V)[] ? V : never
- }[]
-
- export function zipAll(
- ...arrays: T
- ): {
- [K in keyof T]: ReplaceType<
- T[K] extends (infer V)[] ? V : never,
- undefined,
- SiftNone
- >
- }[]
-
- // Aliases
- export {
- concat as join,
- concat as merge,
- concatDeep as joinDeep,
- concatDeep as mergeDeep,
- find as indexOf,
- includes as contains,
- includes as has,
- push as append,
- unshift as prepend,
- is as isArray,
- }
-}
-
-export = SiftArray
diff --git a/@types/Dictionary.d.ts b/@types/Dictionary.d.ts
deleted file mode 100644
index dd71e15..0000000
--- a/@types/Dictionary.d.ts
+++ /dev/null
@@ -1,166 +0,0 @@
-import {
- ExcludeNone,
- FromEntries,
- ObjectFromKeyValueArrays,
- ObjectKey,
- ReadonlyDeep,
- TryIndex
-} from "./Util"
-
-declare namespace SiftDictionary {
- export function copy(dictionary: T): T
-
- export function copyDeep(dictionary: T): T
-
- export function count(
- dictionary: T,
- predicate?: (value: T[K], key: K, dictionary: T) => unknown
- ): number
-
- export function entries(
- dictionary: T
- ): [K, T[K]][]
-
- export function equals(...dictionaries: object[]): boolean
-
- export function equalsDeep(...dictionaries: object[]): boolean
-
- export function every(
- dictionary: T,
- predicate: (value: T[K], key: K, dictionary: Readonly) => unknown
- ): boolean
-
- export function filter(
- dictionary: T,
- predicate: (value: T[K], key: K, dictionary: Readonly) => unknown
- ): Partial
-
- export function flatten(
- dictionary: T,
- depth?: number
- ): Record
-
- export function flip(
- dictionary: T
- ): Record
-
- export function freeze(dictionary: T): Readonly
-
- export function freezeDeep(dictionary: T): ReadonlyDeep
-
- export function fromArrays(
- keys: K[],
- values: V[]
- ): ObjectFromKeyValueArrays
-
- export function fromEntries(
- entries: T
- ): FromEntries
-
- export function has(dictionary: T, key: unknown): boolean
-
- export function includes(
- dictionary: T,
- value: unknown
- ): boolean
-
- export function keys(dictionary: T): K[]
-
- export function map<
- T extends object,
- MV,
- MK extends ObjectKey,
- K extends keyof T
- >(
- dictionary: T,
- mapper: (
- value: T[K],
- key: K,
- dictionary: Readonly
- ) => LuaTuple<[newValue: MV, newKey: MK]> | undefined
- ): {
- [key in MK]: MV
- }
-
- export function map(
- dictionary: T,
- mapper: (value: T[K], key: K, dictionary: Readonly) => MV | undefined
- ): {
- [key in K]: MV
- }
-
- export function merge(
- ...dictionaries: T
- ): ExcludeNone>
-
- export function mergeDeep(
- ...dictionaries: T
- ): ExcludeNone>
-
- export function removeKey(
- dictionary: T,
- key: K
- ): Omit
-
- export function removeKeys(
- dictionary: T,
- ...keys: K[]
- ): Omit
-
- export function removeValue(
- dictionary: T,
- value: V
- ): ExcludeMembers
-
- export function removeValues(
- dictionary: T,
- ...values: V
- ): ExcludeMembers
-
- export function set(
- dictionary: T,
- key: K,
- value: V
- ): T & { [key in K]: V }
-
- export function set(
- dictionary: T,
- key: K,
- value: V
- ): T & { [key in K]: V }
-
- export function some(
- dictionary: T,
- predicate: (value: T[K], key: K, dictionary: Readonly) => unknown
- ): boolean
-
- export function update<
- T extends object,
- K extends ObjectKey,
- X = TryIndex,
- Y = undefined
- >(
- dictionary: T,
- key: K,
- updater?: (value: TryIndex, key: K) => X,
- callback?: (key: K) => Y
- ): (TryIndex extends undefined
- ? {
- [key in keyof T]: key extends K ? X : T[key]
- }
- : {
- [key in keyof T]: key extends K ? Y : T[key]
- }) & { [key in K]: X }
-
- export function values(dictionary: T): T[keyof T][]
-
- export function withKeys(
- dictionary: T,
- ...keys: K[]
- ): Pick
-
- // Aliases
- export { merge as join, mergeDeep as joinDeep }
-}
-
-export = SiftDictionary
diff --git a/@types/Set.d.ts b/@types/Set.d.ts
deleted file mode 100644
index 843a702..0000000
--- a/@types/Set.d.ts
+++ /dev/null
@@ -1,53 +0,0 @@
-import type { AnySet } from "./Util"
-
-declare namespace SiftSet {
- export function add(set: Set, ...values: I[]): Set
-
- export function copy(set: T): T
-
- export function count>(
- set: S,
- predicate?: (item: T) => unknown
- ): number
-
- export function difference(set: Set, ...sets: Set[]): Set
-
- export function differenceSymmetric(set: Set, ...sets: Set[]): Set
-
- export function filter>(
- set: S,
- predicate: (item: T, set: Readonly) => unknown
- ): Set
-
- export function fromArray(array: T[]): Set
-
- export function has(set: AnySet, item: unknown): boolean
-
- export function intersection(...sets: Set[]): Set
-
- export function isSubset(
- subset: A,
- superset: B
- ): boolean
-
- export function isSuperset(
- superset: A,
- subset: B
- ): boolean
-
- export function map>(
- set: S,
- mapper: (item: T, set: Readonly) => R
- ): Set
-
- export function merge(...sets: Set[]): Set
-
- export function subtract(set: S, ...values: unknown[]): S
-
- export function toArray(set: Set): T[]
-
- // Aliases
- export { merge as join, merge as union, subtract as delete }
-}
-
-export = SiftSet
diff --git a/@types/Util.d.ts b/@types/Util.d.ts
deleted file mode 100644
index e2d8c0a..0000000
--- a/@types/Util.d.ts
+++ /dev/null
@@ -1,49 +0,0 @@
-export type SiftNone = { readonly __none__: unique symbol }
-export type ExcludeNone = Exclude
-export type ObjectKey = string | number | symbol
-export type AnySet = Set
-
-export type FromEntries = {
- [P in T[number][0]]: Extract[1]
-}
-
-export type ReadonlyDeep = T extends (infer U)[]
- ? ReadonlyDeepArray
- : T extends Callback
- ? T
- : T extends object
- ? ReadonlyDeepObject
- : T
-
-export type ObjectFromKeyValueArrays<
- Keys extends Array,
- Values extends Array
-> = ObjectFromKeyValuePairs>
-
-export type ReplaceType = F extends T ? Exclude | R : T
-
-export type TryIndex = K extends keyof T ? T[K] : undefined
-
-interface ReadonlyDeepArray extends ReadonlyArray> {}
-
-type ReadonlyDeepObject = {
- readonly [P in keyof T]: ReadonlyDeep
-}
-
-type KeyValuePairsFromLists<
- Keys extends Array,
- Values extends Array
-> = {
- [index in keyof Keys]: index extends keyof Values
- ? [Keys[index], Values[index]]
- : never
-}
-
-type ObjectFromKeyValuePairs<
- KV extends [ObjectKey, any][],
- T = {
- [index in keyof KV]: KV[index] extends [ObjectKey, any]
- ? Record
- : never
- }
-> = UnionToIntersection
diff --git a/@types/index.d.ts b/@types/index.d.ts
deleted file mode 100644
index 05946dc..0000000
--- a/@types/index.d.ts
+++ /dev/null
@@ -1,19 +0,0 @@
-import type { SiftNone } from "./Util"
-
-import SiftArray from "./Array"
-import SiftDictionary from "./Dictionary"
-import SiftSet from "./Set"
-
-declare namespace Sift {
- export const None: SiftNone
- export type None = SiftNone
-
- export {
- SiftArray as Array,
- SiftArray as List,
- SiftDictionary as Dictionary,
- SiftSet as Set,
- }
-}
-
-export = Sift
diff --git a/README.md b/README.md
index bb2b1a8..90e3175 100644
--- a/README.md
+++ b/README.md
@@ -100,28 +100,3 @@ As per the recommendations in [Llama's README][freddylist/llama], the following
- Organised tests. `*.spec` files are now alongside their source files, making it easier to locate them.
- Documentation is now generated using [@upliftgames' moonwave][upliftgames/moonwave] (Docusaurus). This makes it quick and easy to add new documentation, and provides a pleasant experience for the user.
- Built-in TypeScript typings.
-
-## What's New?
-
-### Arrays (Lists)
-
-- `at`: Get an element at a specific index (negative indices are supported).
-- `difference`: Returns an array of values that are in the first array, but not in the other arrays.
-- `differenceSymmetric`: Returns an array of values that are in the first array, but not in the other arrays, and vice versa.
-- `freeze`: Freeze an array.
-- `freezeDeep`: Freeze an array and all nested arrays.
-- `is`: Check if the passed value is an array.
-- `shuffle`: Shuffle the elements of an array to a random order.
-
-### Dictionaries
-
-- `entries`: Get the entries of a dictionary as an array of key-value pairs.
-- `freeze`: Freeze a dictionary.
-- `freezeDeep`: Freeze a dictionary and all nested dictionaries.
-- `fromEntries`: Create a dictionary from an array of key-value pairs.
-
-### Sets
-
-- `count`: Get the number of elements in a set.
-- `difference`: Returns a set of values that are in the first set, but not in the other sets.
-- `differenceSymmetric`: Returns a set of values that are in the first set, but not in the other sets, and vice versa.
diff --git a/docs/Examples.md b/docs/Examples.md
deleted file mode 100644
index 2ef92b5..0000000
--- a/docs/Examples.md
+++ /dev/null
@@ -1,77 +0,0 @@
----
-sidebar_position: 3
----
-
-Sift contains a number of useful functions for working with data structures. These functions are available as static methods on the Sift module (refer to the [API documentation](/api) for more details).
-
-```lua
-local Sift = require(path.to.Sift)
-```
-
-Sift also exports Luau types, which can be accessed from the Sift module itself, or via the dedicated Types module, which is exported as `Sift.Types`.
-
-### Combining Data
-
-```lua
-local dictionary1 = { a = 1, b = 2 }
-local dictionary2 = { c = 3, d = 4 }
-
-local result = Sift.Dictionary.merge(dictionary1, dictionary2) -- { a = 1, b = 2, c = 3, d = 4 }
-```
-
-```lua
-local array1 = { 1, 2, 3 }
-local array2 = { 4, 5, 6 }
-
-local result = Sift.Array.concat(array1, array2) -- { 1, 2, 3, 4, 5, 6 }
-```
-
-### Filtering Data
-
-The following example filters out all uneven numbers from an array of numbers.
-
-```lua
-local array = { 1, 2, 3, 4, 5, 6 }
-
-local result = Sift.Array.filter(array, function(value)
- return value % 2 == 0
-end) -- { 2, 4, 6 }
-```
-
-Dictionaries can also be filtered in Sift!
-
-```lua
-local dictionary = { a = 1, b = 2, c = 3, d = 4 }
-
-local result = Sift.Dictionary.filter(dictionary, function(value)
- return value % 2 == 0
-end) -- { b = 2, d = 4 }
-```
-
-### Removing Duplicates
-
-There's a few different methods for removing duplicates from an array or dictionary.
-
-The following example removes all duplicate values from an array using sets.
-
-```lua
-local array = { "hello", "world", "world", "cat", "dog" }
-
-local set = Sift.Set.fromArray(array) -- { "hello" = true, "world" = true, "cat" = true, "dog" = true }
-
-local result = Sift.Set.toArray(set) -- { "hello", "world", "cat", "dog" }
-```
-
-The same could also be accomplished using a reducer.
-
-```lua
-local array = { "hello", "world", "world", "cat", "dog" }
-
-local result = Sift.Array.reduce(array, function(accumulator, value)
- if not Sift.Array.includes(accumulator, value) then
- return Sift.Array.push(accumulator, value)
- end
-
- return accumulator
-end, {}) -- { "hello", "world", "cat", "dog" }
-```
diff --git a/docs/Installation.md b/docs/Installation.md
deleted file mode 100644
index 1756841..0000000
--- a/docs/Installation.md
+++ /dev/null
@@ -1,61 +0,0 @@
----
-sidebar_position: 2
----
-
-
-
-[sift]: https://github.com/cxmeel/sift
-[sift/releases]: https://github.com/cxmeel/sift/releases
-[sift/wally]: https://wally.run/package/cxmeel/sift
-[sift/roblox]: https://www.roblox.com/library/9486684823
-[sift/itch.io]: https://cxmeel.itch.io/sift
-[sift/npm]: https://npmjs.com/package/@rbxts/sift
-
-Sift is available from [Wally][sift/wally], [Itch.io][sift/itch.io], the [Roblox Library][sift/roblox], and [GitHub releases][sift/releases].
-
-While Sift is 100% free and open source, if you feel like sponsoring, Sift is also available on [Itch.io][sift/itch.io].
-
-### Wally
-
-Wally is a CLI package manager (much like NPM, Yarn or Cargo) for Roblox by @UpliftGames. Find out more at https://github.com/upliftgames/wally.
-
-```toml
-# wally.toml
-
-[dependencies]
-Sift = "cxmeel/sift@=0.0.1"
-```
-
-```shell
-$ wally install
-```
-
-### TypeScript
-
-v0.0.1 of Sift includes TypeScript definitions. This means Sift is now compatible with roblox-ts. Refer to the Luau docs for API details.
-
-```shell
-$ npm install @rbxts/sift
-```
-
-[View on NPM →][sift/npm]
-
-```ts
-// example.ts
-import Sift from "@rbxts/sift"
-
-Sift.Dictionary.merge({ a: 1, c: 2 }, { b: 3, c: Sift.None }) // { a: 1, b: 3 }
-```
-
-Alternatively, you can use tree-shaking to access the modules directly.
-
-```ts
-// example.ts
-import { Dictionary, None } from "@rbxts/sift"
-
-Dictionary.merge({ a: 1, c: 2 }, { b: 3, c: None }) // { a: 1, b: 3 }
-```
-
-### Manual Installation
-
-Grab a copy [from the Roblox Library][sift/roblox] or [GitHub releases][sift/releases], and drop it into Studio. The Sift model file can be synced in using Rojo.
diff --git a/package.json b/package.json
index 9591aca..4b791aa 100644
--- a/package.json
+++ b/package.json
@@ -1,17 +1,16 @@
{
"name": "@rbxts/sift",
- "version": "0.0.8",
+ "version": "0.1.0",
"description": "Immutable data library for Luau",
"main": "out/init.lua",
- "types": "out/index.d.ts",
+ "types": "@types/index.d.ts",
"publishConfig": {
"access": "public"
},
"scripts": {
"build": "rbxtsc --type=package --rojo=''",
"watch": "rbxtsc -w",
- "prepublishOnly": "npm run build",
- "prepare": "husky install"
+ "prepublishOnly": "npm run build"
},
"repository": {
"type": "git",
diff --git a/sourcemap.json b/sourcemap.json
deleted file mode 100644
index a41e6c4..0000000
--- a/sourcemap.json
+++ /dev/null
@@ -1 +0,0 @@
-{"name":"Sift","className":"ModuleScript","filePaths":["src\\init.luau","default.project.json"],"children":[{"name":"Array","className":"ModuleScript","filePaths":["src\\Array\\init.luau"],"children":[{"name":"concatDeep","className":"ModuleScript","filePaths":["src\\Array\\concatDeep.luau"]},{"name":"copy","className":"ModuleScript","filePaths":["src\\Array\\copy.luau"]},{"name":"copyDeep","className":"ModuleScript","filePaths":["src\\Array\\copyDeep.luau"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Array\\count.luau"]},{"name":"create","className":"ModuleScript","filePaths":["src\\Array\\create.luau"]},{"name":"difference","className":"ModuleScript","filePaths":["src\\Array\\difference.luau"]},{"name":"differenceSymmetric","className":"ModuleScript","filePaths":["src\\Array\\differenceSymmetric.luau"]},{"name":"equals","className":"ModuleScript","filePaths":["src\\Array\\equals.luau"]},{"name":"equalsDeep","className":"ModuleScript","filePaths":["src\\Array\\equalsDeep.luau"]},{"name":"every","className":"ModuleScript","filePaths":["src\\Array\\every.luau"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Array\\filter.luau"]},{"name":"find","className":"ModuleScript","filePaths":["src\\Array\\find.luau"]},{"name":"findLast","className":"ModuleScript","filePaths":["src\\Array\\findLast.luau"]},{"name":"findWhere","className":"ModuleScript","filePaths":["src\\Array\\findWhere.luau"]},{"name":"findWhereLast","className":"ModuleScript","filePaths":["src\\Array\\findWhereLast.luau"]},{"name":"first","className":"ModuleScript","filePaths":["src\\Array\\first.luau"]},{"name":"flatten","className":"ModuleScript","filePaths":["src\\Array\\flatten.luau"]},{"name":"freeze","className":"ModuleScript","filePaths":["src\\Array\\freeze.luau"]},{"name":"freezeDeep","className":"ModuleScript","filePaths":["src\\Array\\freezeDeep.luau"]},{"name":"includes","className":"ModuleScript","filePaths":["src\\Array\\includes.luau"]},{"name":"insert","className":"ModuleScript","filePaths":["src\\Array\\insert.luau"]},{"name":"is","className":"ModuleScript","filePaths":["src\\Array\\is.luau"]},{"name":"last","className":"ModuleScript","filePaths":["src\\Array\\last.luau"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Array\\map.luau"]},{"name":"pop","className":"ModuleScript","filePaths":["src\\Array\\pop.luau"]},{"name":"push","className":"ModuleScript","filePaths":["src\\Array\\push.luau"]},{"name":"reduce","className":"ModuleScript","filePaths":["src\\Array\\reduce.luau"]},{"name":"reduceRight","className":"ModuleScript","filePaths":["src\\Array\\reduceRight.luau"]},{"name":"removeIndex","className":"ModuleScript","filePaths":["src\\Array\\removeIndex.luau"]},{"name":"removeValues","className":"ModuleScript","filePaths":["src\\Array\\removeValues.luau"]},{"name":"reverse","className":"ModuleScript","filePaths":["src\\Array\\reverse.luau"]},{"name":"slice","className":"ModuleScript","filePaths":["src\\Array\\slice.luau"]},{"name":"update","className":"ModuleScript","filePaths":["src\\Array\\update.luau"]},{"name":"zip","className":"ModuleScript","filePaths":["src\\Array\\zip.luau"]},{"name":"zipAll","className":"ModuleScript","filePaths":["src\\Array\\zipAll.luau"]},{"name":"at","className":"ModuleScript","filePaths":["src\\Array\\at.luau"]},{"name":"concat","className":"ModuleScript","filePaths":["src\\Array\\concat.luau"]},{"name":"removeIndices","className":"ModuleScript","filePaths":["src\\Array\\removeIndices.luau"]},{"name":"removeValue","className":"ModuleScript","filePaths":["src\\Array\\removeValue.luau"]},{"name":"set","className":"ModuleScript","filePaths":["src\\Array\\set.luau"]},{"name":"shift","className":"ModuleScript","filePaths":["src\\Array\\shift.luau"]},{"name":"shuffle","className":"ModuleScript","filePaths":["src\\Array\\shuffle.luau"]},{"name":"some","className":"ModuleScript","filePaths":["src\\Array\\some.luau"]},{"name":"sort","className":"ModuleScript","filePaths":["src\\Array\\sort.luau"]},{"name":"splice","className":"ModuleScript","filePaths":["src\\Array\\splice.luau"]},{"name":"toSet","className":"ModuleScript","filePaths":["src\\Array\\toSet.luau"]},{"name":"unshift","className":"ModuleScript","filePaths":["src\\Array\\unshift.luau"]}]},{"name":"Dictionary","className":"ModuleScript","filePaths":["src\\Dictionary\\init.luau"],"children":[{"name":"copyDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\copyDeep.luau"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Dictionary\\count.luau"]},{"name":"entries","className":"ModuleScript","filePaths":["src\\Dictionary\\entries.luau"]},{"name":"equals","className":"ModuleScript","filePaths":["src\\Dictionary\\equals.luau"]},{"name":"equalsDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\equalsDeep.luau"]},{"name":"every","className":"ModuleScript","filePaths":["src\\Dictionary\\every.luau"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Dictionary\\filter.luau"]},{"name":"flatten","className":"ModuleScript","filePaths":["src\\Dictionary\\flatten.luau"]},{"name":"flip","className":"ModuleScript","filePaths":["src\\Dictionary\\flip.luau"]},{"name":"freeze","className":"ModuleScript","filePaths":["src\\Dictionary\\freeze.luau"]},{"name":"freezeDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\freezeDeep.luau"]},{"name":"fromArrays","className":"ModuleScript","filePaths":["src\\Dictionary\\fromArrays.luau"]},{"name":"fromEntries","className":"ModuleScript","filePaths":["src\\Dictionary\\fromEntries.luau"]},{"name":"has","className":"ModuleScript","filePaths":["src\\Dictionary\\has.luau"]},{"name":"includes","className":"ModuleScript","filePaths":["src\\Dictionary\\includes.luau"]},{"name":"keys","className":"ModuleScript","filePaths":["src\\Dictionary\\keys.luau"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Dictionary\\map.luau"]},{"name":"merge","className":"ModuleScript","filePaths":["src\\Dictionary\\merge.luau"]},{"name":"mergeDeep","className":"ModuleScript","filePaths":["src\\Dictionary\\mergeDeep.luau"]},{"name":"removeKey","className":"ModuleScript","filePaths":["src\\Dictionary\\removeKey.luau"]},{"name":"removeKeys","className":"ModuleScript","filePaths":["src\\Dictionary\\removeKeys.luau"]},{"name":"removeValue","className":"ModuleScript","filePaths":["src\\Dictionary\\removeValue.luau"]},{"name":"removeValues","className":"ModuleScript","filePaths":["src\\Dictionary\\removeValues.luau"]},{"name":"set","className":"ModuleScript","filePaths":["src\\Dictionary\\set.luau"]},{"name":"some","className":"ModuleScript","filePaths":["src\\Dictionary\\some.luau"]},{"name":"update","className":"ModuleScript","filePaths":["src\\Dictionary\\update.luau"]},{"name":"values","className":"ModuleScript","filePaths":["src\\Dictionary\\values.luau"]},{"name":"withKeys","className":"ModuleScript","filePaths":["src\\Dictionary\\withKeys.luau"]},{"name":"copy","className":"ModuleScript","filePaths":["src\\Dictionary\\copy.luau"]}]},{"name":"Set","className":"ModuleScript","filePaths":["src\\Set\\init.luau"],"children":[{"name":"add","className":"ModuleScript","filePaths":["src\\Set\\add.luau"]},{"name":"copy","className":"ModuleScript","filePaths":["src\\Set\\copy.luau"]},{"name":"count","className":"ModuleScript","filePaths":["src\\Set\\count.luau"]},{"name":"delete","className":"ModuleScript","filePaths":["src\\Set\\delete.luau"]},{"name":"difference","className":"ModuleScript","filePaths":["src\\Set\\difference.luau"]},{"name":"differenceSymmetric","className":"ModuleScript","filePaths":["src\\Set\\differenceSymmetric.luau"]},{"name":"filter","className":"ModuleScript","filePaths":["src\\Set\\filter.luau"]},{"name":"fromArray","className":"ModuleScript","filePaths":["src\\Set\\fromArray.luau"]},{"name":"has","className":"ModuleScript","filePaths":["src\\Set\\has.luau"]},{"name":"intersection","className":"ModuleScript","filePaths":["src\\Set\\intersection.luau"]},{"name":"isSubset","className":"ModuleScript","filePaths":["src\\Set\\isSubset.luau"]},{"name":"isSuperset","className":"ModuleScript","filePaths":["src\\Set\\isSuperset.luau"]},{"name":"map","className":"ModuleScript","filePaths":["src\\Set\\map.luau"]},{"name":"merge","className":"ModuleScript","filePaths":["src\\Set\\merge.luau"]},{"name":"toArray","className":"ModuleScript","filePaths":["src\\Set\\toArray.luau"]}]},{"name":"Util","className":"ModuleScript","filePaths":["src\\Util\\init.luau"],"children":[{"name":"equalObjects","className":"ModuleScript","filePaths":["src\\Util\\equalObjects.luau"]},{"name":"func","className":"ModuleScript","filePaths":["src\\Util\\func.luau"]},{"name":"isEmpty","className":"ModuleScript","filePaths":["src\\Util\\isEmpty.luau"]}]},{"name":"Types","className":"ModuleScript","filePaths":["src\\Types.luau"]},{"name":"None","className":"ModuleScript","filePaths":["src\\None.luau"]}]}
\ No newline at end of file
diff --git a/src/Array/at.luau b/src/Array/at.luau
index b7cdbd5..dbe90fc 100644
--- a/src/Array/at.luau
+++ b/src/Array/at.luau
@@ -1,26 +1,19 @@
---!strict
--[=[
- @function at
- @within Array
+ @within Array
- @param array {T} -- The array to get the value from.
- @param index number -- The index to get the value from (can be negative).
- @return T -- The value at the given index.
+ Pick out a value from an array by index, with support for negative indices.
+ Negative indices are counted from the end of the array. Because Lua uses 1-based indexing, an index of 0 will be treated as 1.
- Gets a value from an array at the given index.
-
- ```lua
- local array = { 1, 2, 3 }
-
- local value = At(array, 1) -- 1
- local value = At(array, 0) -- 3
- ```
+ ```lua
+ at({ "a", "b", "c", "d", "e" }, 2) -- "b"
+ at({ "a", "b", "c", "d", "e" }, -1) -- "e"
+ ```
]=]
local function at(array: { T }, index: number): T
- local length = #array
-
- if index < 1 then
- index += length
+ if index == 0 then
+ index = 1
+ elseif index < 0 then
+ index += #array + 1
end
return array[index]
diff --git a/src/Array/concat.luau b/src/Array/concat.luau
index 76e8abb..1808944 100644
--- a/src/Array/concat.luau
+++ b/src/Array/concat.luau
@@ -1,46 +1,25 @@
---!strict
-local Sift = script.Parent.Parent
-
-local None = require(Sift.None)
-
--[=[
- @function concat
- @within Array
-
- @param ... ...any -- The arrays to concatenate.
- @return {T} -- The concatenated array.
-
- Joins multiple arrays together into a single array.
+ @within Array
- #### Aliases
+ Concatenates the elements of the given arrays into a new array.
- `join`, `merge`
+ ```lua
+ local array1 = { 1, 2, 3 }
+ local array2 = { 4, 5, 6 }
- ```lua
- local table1 = { 1, 2, 3 }
- local table2 = { 4, 5, 6 }
-
- local new = Concat(table1, table2) -- { 1, 2, 3, 4, 5, 6 }
- ```
+ concat(array1, array2) -- {1, 2, 3, 4, 5, 6}
+ ```
]=]
-local function concat(...: any): { T }
- local result = {}
-
- for arrayIndex = 1, select("#", ...) do
- local array = select(arrayIndex, ...)
-
- if type(array) ~= "table" then
- continue
- end
+local function concat(...: { T })
+ local out = {}
- for _, item in ipairs(array) do
- if item ~= None then
- table.insert(result, item)
- end
+ for _, array in { ... } do
+ for _, value in array do
+ table.insert(out, value)
end
end
- return result
+ return out
end
return concat
diff --git a/src/Array/concatDeep.luau b/src/Array/concatDeep.luau
deleted file mode 100644
index 519b4f2..0000000
--- a/src/Array/concatDeep.luau
+++ /dev/null
@@ -1,52 +0,0 @@
---!strict
-local Sift = script.Parent.Parent
-
-local CopyDeep = require(script.Parent.copyDeep)
-local None = require(Sift.None)
-
---[=[
- @function concatDeep
- @within Array
-
- @param ... ...any -- The arrays to concatenate.
- @return {T} -- The concatenated array.
-
- Joins multiple arrays together into a single array, with deep copies of all
- nested arrays.
-
- #### Aliases
-
- `joinDeep`, `mergeDeep`
-
- ```lua
- local table1 = { 1, 2, { 3, 4 } }
- local table2 = { 5, 6, { 7, 8 } }
-
- local new = ConcatDeep(table1, table2) -- { 1, 2, { 3, 4 }, 5, 6, { 7, 8 } }
- ```
-]=]
-local function concatDeep(...: any): { T }
- local result = {}
-
- for arrayIndex = 1, select("#", ...) do
- local array = select(arrayIndex, ...)
-
- if type(array) ~= "table" then
- continue
- end
-
- for _, value in ipairs(array) do
- if value ~= None then
- if type(value) == "table" then
- table.insert(result, CopyDeep(value))
- else
- table.insert(result, value)
- end
- end
- end
- end
-
- return result
-end
-
-return concatDeep
diff --git a/src/Array/copy.luau b/src/Array/copy.luau
index bc31cc6..49a14f7 100644
--- a/src/Array/copy.luau
+++ b/src/Array/copy.luau
@@ -1,19 +1,13 @@
---!strict
--[=[
- @function copy
- @within Array
+ @within Array
+ @function copy
+ @param array { T }
+ @return { T }
- @param array {T} -- The array to copy.
- @return {T} -- The copied array.
+ Returns a shallow copy of the array. Use [Array.copyDeep] to copy nested arrays.
- Copies an array.
-
- ```lua
- local array = { 1, 2, 3 }
-
- local new = Copy(array) -- { 1, 2, 3 }
-
- print(new == array) -- false
- ```
+ ```lua
+ copy({ 1, 2, 3 }) -- { 1, 2, 3 }
+ ```
]=]
return table.clone
diff --git a/src/Array/copyDeep.luau b/src/Array/copyDeep.luau
index 36ea759..1e4e203 100644
--- a/src/Array/copyDeep.luau
+++ b/src/Array/copyDeep.luau
@@ -1,32 +1,25 @@
---!strict
--[=[
- @function copyDeep
- @within Array
+ @within Array
- @param array {T} -- The array to copy.
- @return {T} -- The copied array.
+ Returns a deep copy of the given array. This means that all tables within the array are also copied.
- Copies an array, with deep copies of all nested arrays.
-
- ```lua
- local array = { 1, 2, 3, { 4, 5 } }
-
- local result = CopyDeep(array) -- { 1, 2, 3, { 4, 5 } }
-
- print(result == array) -- false
- print(result[4] == array[4]) -- false
- ```
+ ```lua
+ local array = {{ 1, 2 }, { 3, 4 }}
+ copyDeep(array) -- {{ 1, 2 }, { 3, 4 }}
+ ```
]=]
local function copyDeep(array: { T }): { T }
- local result = table.clone(array)
+ local out: any = {}
- for index, value in array do
- if type(value) == "table" then
- result[index] = copyDeep(value) :: any
+ for _, value in array do
+ if typeof(value) == "table" then
+ table.insert(out, copyDeep(value))
+ else
+ table.insert(out, value)
end
end
- return result
+ return out
end
return copyDeep
diff --git a/src/Array/count.luau b/src/Array/count.luau
index ae569fc..4c63418 100644
--- a/src/Array/count.luau
+++ b/src/Array/count.luau
@@ -1,38 +1,23 @@
---!strict
-local Sift = script.Parent.Parent
-
-local Util = require(Sift.Util)
-
--[=[
- @function count
- @within Array
+ @within Array
- @param array {T} -- The array to count the number of items in.
- @param predicate? (value: T, index: number, array: {T}) -> any -- The predicate to use to filter the array.
- @return number -- The number of items in the array.
+ Returns the number of elements in the array, optionally filtered by a predicate.
- Counts the number of items in an array.
+ ```lua
+ local array = { 1, 2, 3, 4, 5 }
- ```lua
- local array = { 1, 2, 3 }
-
- local value = Count(array) -- 3
- local value = Count(array, function(item, index)
- return item == 2
- end) -- 1
- ```
+ count(array) -- 5
+ count(array, function(value)
+ return value > 3
+ end) -- 2
+ ```
]=]
-local function count(
- array: { T },
- predicate: ((value: T, index: number, array: { T }) -> any)?
-): number
+local function count(array: { T }, predicate: ((value: T, index: number) -> boolean)?): number
local counter = 0
- predicate = if type(predicate) == "function" then predicate else Util.func.truthy
-
- for index, value in ipairs(array) do
- if predicate(value, index, array) then
- counter += 1
+ for index, value in array do
+ if not predicate or predicate(value, index) then
+ counter = counter + 1
end
end
diff --git a/src/Array/create.luau b/src/Array/create.luau
index b6e081c..0071060 100644
--- a/src/Array/create.luau
+++ b/src/Array/create.luau
@@ -1,19 +1,15 @@
---!strict
--[=[
- @function create
- @within Array
-
- @param length number -- The length of the array to create.
- @param value? T -- The value to fill the array with.
- @return {T} -- The created array.
-
- Creates an array of the given length, filled with the given value.
- This is just a wrapper around `table.create`.
-
- ```lua
- local array = Create(3, "Hello")
-
- print(array) -- { "Hello", "Hello", "Hello" }
- ```
+ @within Array
+ @function create
+ @param count number
+ @param value T?
+ @return { T }
+
+ Creates a new array with `count` elements, each initialized to `value`.
+
+ ```lua
+ create(3) -- { nil, nil, nil }
+ create(3, true) -- { true, true, true }
+ ```
]=]
return table.create
diff --git a/src/Array/difference.luau b/src/Array/difference.luau
deleted file mode 100644
index 90c5ab5..0000000
--- a/src/Array/difference.luau
+++ /dev/null
@@ -1,42 +0,0 @@
---!strict
-local T = require(script.Parent.Parent.Types)
-
-local toSet = require(script.Parent.toSet)
-local toArray = require(script.Parent.Parent.Set.toArray)
-local setDifference = require(script.Parent.Parent.Set.difference)
-
---[=[
- @function difference
- @within Array
-
- @param array Array -- The array to compare.
- @param ... ...Array -- The arrays to compare against.
- @return Array -- The difference between the arrays.
-
- Returns an array of values that are in the first array, but not in the other arrays.
-
- ```lua
- local array1 = { "hello", "world" }
- local array2 = { "cat", "dog", "hello" }
-
- local difference = Difference(array1, array2) -- { "world" }
- ```
-]=]
-local function difference(array: T.Array, ...: T.Array): T.Array
- local arraySet = toSet(array)
- local otherSets = {}
-
- for _, nextArray in { ... } do
- if typeof(nextArray) ~= "table" then
- continue
- end
-
- table.insert(otherSets, toSet(nextArray))
- end
-
- local differenceSet = setDifference(arraySet, unpack(otherSets))
-
- return toArray(differenceSet)
-end
-
-return difference
diff --git a/src/Array/difference.luau.todo b/src/Array/difference.luau.todo
new file mode 100644
index 0000000..6c399e6
--- /dev/null
+++ b/src/Array/difference.luau.todo
@@ -0,0 +1 @@
+requires sets
diff --git a/src/Array/differenceSymmetric.luau b/src/Array/differenceSymmetric.luau
deleted file mode 100644
index 54e358b..0000000
--- a/src/Array/differenceSymmetric.luau
+++ /dev/null
@@ -1,42 +0,0 @@
---!strict
-local T = require(script.Parent.Parent.Types)
-
-local toSet = require(script.Parent.toSet)
-local toArray = require(script.Parent.Parent.Set.toArray)
-local setDifferenceSymmetric = require(script.Parent.Parent.Set.differenceSymmetric)
-
---[=[
- @function differenceSymmetric
- @within Array
-
- @param array Array -- The array to compare.
- @param ... ...Array -- The arrays to compare against.
- @return Array -- The symmetric difference between the arrays.
-
- Returns an array of values that are in the first array, but not in the other arrays, and vice versa.
-
- ```lua
- local array1 = { "hello", "world" }
- local array2 = { "cat", "dog", "hello" }
-
- local difference = DifferenceSymmetric(array1, array2) -- { "world", "cat", "dog" }
- ```
-]=]
-local function differenceSymmetric(array: T.Array, ...: T.Array): T.Array
- local arraySet = toSet(array)
- local otherSets = {}
-
- for _, nextArray in { ... } do
- if typeof(nextArray) ~= "table" then
- continue
- end
-
- table.insert(otherSets, toSet(nextArray))
- end
-
- local differenceSet = setDifferenceSymmetric(arraySet, unpack(otherSets))
-
- return toArray(differenceSet)
-end
-
-return differenceSymmetric
diff --git a/src/Array/differenceSymmetric.luau.todo b/src/Array/differenceSymmetric.luau.todo
new file mode 100644
index 0000000..6c399e6
--- /dev/null
+++ b/src/Array/differenceSymmetric.luau.todo
@@ -0,0 +1 @@
+requires sets
diff --git a/src/Array/equals.luau b/src/Array/equals.luau
index c468d79..02a9bb5 100644
--- a/src/Array/equals.luau
+++ b/src/Array/equals.luau
@@ -1,21 +1,16 @@
---!strict
-local Sift = script.Parent.Parent
+local Util = require("@Sift/Util")
-local Util = require(Sift.Util)
-
-local function compare(a, b)
- if type(a) ~= "table" or type(b) ~= "table" then
+local function compare(a: any, b: any)
+ if typeof(a) ~= "table" or typeof(b) ~= "table" then
return a == b
end
- local aLength = #a
-
- if #b ~= aLength then
+ if #a ~= #b then
return false
end
- for i = 1, aLength do
- if a[i] ~= b[i] then
+ for index, value in a do
+ if value ~= b[index] then
return false
end
end
@@ -24,35 +19,27 @@ local function compare(a, b)
end
--[=[
- @function equals
- @within Array
+ @within Array
- @param ... ...{any} -- The arrays to compare.
- @return boolean -- Whether the arrays are equal.
+ Returns whether or not all of the given arrays are equal to each other.
- Compares two arrays for equality.
+ ```lua
+ local array1 = { 1, 2, 3 }
+ local array2 = { 1, 2, 3 }
- ```lua
- local array = { 1, 2, 3 }
- local other = { 1, 2, 3 }
-
- local value = Equals(array, other) -- true
- local value = Equals(array, other, { 1, 2, 3 }) -- true
- local value = Equals(array, other, { 1, 2, 4 }) -- false
- ```
+ equals(array1, array2) -- true
+ ```
]=]
-local function equals(...: { T }): boolean
- if Util.equalObjects(...) then
+local function equals(...: any): boolean
+ if Util.areEqual(...) then
return true
end
- local totalArgs = select("#", ...)
- local firstItem = select(1, ...)
-
- for i = 2, totalArgs do
- local item = select(i, ...)
+ local args = { ... }
+ local first = table.remove(args, 1)
- if not compare(firstItem, item) then
+ for _, array in args do
+ if not compare(first, array) then
return false
end
end
diff --git a/src/Array/equalsDeep.luau b/src/Array/equalsDeep.luau
index 3e8225a..7fa3628 100644
--- a/src/Array/equalsDeep.luau
+++ b/src/Array/equalsDeep.luau
@@ -1,21 +1,16 @@
---!strict
-local Sift = script.Parent.Parent
+local Util = require("@Sift/Util")
-local Util = require(Sift.Util)
-
-local function compareDeep(a, b)
- if type(a) ~= "table" or type(b) ~= "table" then
+local function compare(a: any, b: any)
+ if typeof(a) ~= "table" or typeof(b) ~= "table" then
return a == b
end
- local aLength = #a
-
- if #b ~= aLength then
+ if #a ~= #b then
return false
end
- for i = 1, aLength do
- if not compareDeep(a[i], b[i]) then
+ for index, value in a do
+ if not compare(value, b[index]) then
return false
end
end
@@ -24,35 +19,27 @@ local function compareDeep(a, b)
end
--[=[
- @function equalsDeep
- @within Array
+ @within Array
- @param ... ...{any} -- The arrays to compare.
- @return boolean -- Whether the arrays are equal.
+ Returns whether or not all of the provided values are deeply equal to each other. Use this function to compare nested arrays.
- Compares two arrays for equality using deep comparison.
+ ```lua
+ local array1 = {{ 1, 2 }, { 3, 4 }}
+ local array2 = {{ 1, 2 }, { 4, 5 }}
- ```lua
- local array = { 1, 2, 3, { 4, 5 } }
- local other = { 1, 2, 3, { 4, 5 } }
-
- local value = EqualsDeep(array, other) -- true
- local value = EqualsDeep(array, other, { 1, 2, 3, { 4, 5 } }) -- true
- local value = EqualsDeep(array, other, { 1, 2, 3, { 4, 6 } }) -- false
- ```
+ equalsDeep(array1, array2) -- false
+ ```
]=]
-local function equalsDeep(...: { T }): boolean
- if Util.equalObjects(...) then
+local function equalsDeep(...: any): boolean
+ if Util.areEqual(...) then
return true
end
- local totalArgs = select("#", ...)
- local firstItem = select(1, ...)
-
- for i = 2, totalArgs do
- local item = select(i, ...)
+ local args = { ... }
+ local first = table.remove(args, 1)
- if not compareDeep(firstItem, item) then
+ for _, value in args do
+ if not compare(first, value) then
return false
end
end
diff --git a/src/Array/every.luau b/src/Array/every.luau
index d42399e..6548526 100644
--- a/src/Array/every.luau
+++ b/src/Array/every.luau
@@ -1,32 +1,17 @@
---!strict
--[=[
- @function every
- @within Array
+ @within Array
- @param array {T} -- The array to check.
- @param predicate (value: T, index: number, array: {T}) -> any -- The predicate to use to check the array.
- @return boolean -- Whether every item in the array passes the predicate.
+ Returns `true` if every element in the array passes the test implemented by the provided function. Otherwise, it returns `false`.
- Checks whether every item in the array passes the predicate.
-
- ```lua
- local array = { 1, 2, 3 }
-
- local value = Every(array, function(item, index)
- return item > 0
- end) -- true
-
- local value = Every(array, function(item, index)
- return item > 1
- end) -- false
- ```
+ ```lua
+ every({ 1, 2, 3, 4, 5 }, function(value)
+ return value > 0
+ }) -- true
+ ```
]=]
-local function every(
- array: { T },
- predicate: (value: T, index: number, array: { T }) -> any
-): boolean
- for index, value in ipairs(array) do
- if not predicate(value, index, array) then
+local function every(array: { T }, predicate: (value: T, index: number) -> boolean): boolean
+ for index, value in array do
+ if not predicate(value, index) then
return false
end
end
diff --git a/src/Array/filter.luau b/src/Array/filter.luau
index 877b98c..cdbb1ca 100644
--- a/src/Array/filter.luau
+++ b/src/Array/filter.luau
@@ -1,43 +1,23 @@
---!strict
-local Sift = script.Parent.Parent
-
-local Util = require(Sift.Util)
-
--[=[
- @function filter
- @within Array
-
- @param array {T} -- The array to filter.
- @param filterer? (value: T, index: number, array: {T}) -> any -- The callback to use to filter the array.
- @return {T} -- The filtered array.
+ @within Array
- Filters an array using a filterer callback. Any items that do not pass the filterer will be removed from the array.
+ Filters out elements from an array based on a filter function. The filter function should return `true` to keep the element, and `false` to remove it.
- If no filterer is provided, all items will be kept.
-
- ```lua
- local array = { 1, 2, 3 }
-
- local result = Filter(array, function(item, index)
- return item > 1
- end) -- { 2, 3 }
- ```
+ ```lua
+ filter({ 1, 2, 3, 4, 5}, function(value)
+ return value > 3
+ end) -- { 4, 5 }
]=]
-local function filter(
- array: { T },
- predicate: ((value: T, index: number, array: { T }) -> boolean?)?
-): { T }
- local result = {}
-
- predicate = if type(predicate) == "function" then predicate else Util.func.truthy
+local function filter(array: { T }, filterer: (value: T, index: number) -> boolean): { T }
+ local out = {}
- for index, value in ipairs(array) do
- if predicate(value, index, array) then
- table.insert(result, value)
+ for index, value in array do
+ if filterer(value, index) then
+ table.insert(out, value)
end
end
- return result
+ return out
end
return filter
diff --git a/src/Array/find.luau b/src/Array/find.luau
index 5bca288..209d0f5 100644
--- a/src/Array/find.luau
+++ b/src/Array/find.luau
@@ -1,31 +1,22 @@
---!strict
--[=[
- @function find
- @within Array
+ @within Array
- @param array {T} -- The array to search.
- @param value? any -- The value to search for.
- @param from? number -- The index to start searching from.
- @return number? -- The index of the first item in the array that matches the value.
+ Returns the index of the first occurrence of a value in an array, or `nil` if the value is not found. The search starts at the optional `from` index. If `from` is negative, it is treated as an offset from the end of the array.
- Finds the index of the first item in the array that matches the value. This is
- mostly a wrapper around `table.find`, with the ability to specify a negative
- number as the start index (to search relative to the end of the array).
+ ```lua
+ local array = { "a", "b", "c", "a", "b" }
- #### Aliases
- `indexOf`
-
- ```lua
- local array = { "hello", "world", "hello" }
-
- local index = Find(array, "hello") -- 1
- local index = Find(array, "hello", 2) -- 3
- ```
+ find(array, "a") -- 1
+ find(array, "a", 2) -- 4
+ find(array, "b", -2) -- 5
+ ```
]=]
-local function find(array: { T }, value: any?, from: number?): number?
- local length = #array
-
- from = if type(from) == "number" then if from < 1 then length + from else from else 1
+local function find(array: { T }, value: T, from: number?): number?
+ if from == 0 then
+ from = 1
+ elseif from and from < 0 then
+ from += #array + 1
+ end
return table.find(array, value, from)
end
diff --git a/src/Array/findLast.luau b/src/Array/findLast.luau
index 5755fda..f294068 100644
--- a/src/Array/findLast.luau
+++ b/src/Array/findLast.luau
@@ -1,34 +1,30 @@
---!strict
--[=[
- @function findLast
- @within Array
+ @within Array
- @param array {T} -- The array to search.
- @param value? any -- The value to search for.
- @param from? number -- The index to start searching from.
- @return number? -- The index of the last item in the array that matches the value.
+ Returns the last index at which a given element can be found in the array, or `nil` if it is not present. The array is searched backwards, starting at the optional `from` index. If `from` is negative, it is used as the offset from the end of the array.
- Finds the index of the last item in the array that matches the value.
+ ```lua
+ local array = { "a", "b", "c", "a", "b" }
- ```lua
- local array = { "hello", "world", "hello" }
-
- local index = FindLast(array, "hello") -- 3
- local index = FindLast(array, "hello", 2) -- 1
- ```
+ findLast(array, "b") -- 5
+ findLast(array, "b", 3) -- 2
+ findLast(array, "b", -3) -- 2
+ ```
]=]
-local function findLast(array: { T }, value: any?, from: number?): number?
- local length = #array
-
- from = if type(from) == "number" then if from < 1 then length + from else from else length
+local function findLast(array: { T }, value: T, from: number?): number?
+ if from == 0 then
+ from = 1
+ elseif from and from < 0 then
+ from += #array + 1
+ end
- for index = from, 1, -1 do
- if array[index] == value then
- return index
+ for i = from or #array, 1, -1 do
+ if array[i] == value then
+ return i
end
end
- return
+ return nil
end
return findLast
diff --git a/src/Array/findWhere.luau b/src/Array/findWhere.luau
index a48be9c..4387895 100644
--- a/src/Array/findWhere.luau
+++ b/src/Array/findWhere.luau
@@ -1,39 +1,32 @@
---!strict
--[=[
- @function findWhere
- @within Array
+ @within Array
- @param array {T} -- The array to search.
- @param predicate (value: T, index: number, array: {T}) -> any -- The predicate to use to check the array.
- @param from? number -- The index to start searching from.
- @return number -- The index of the first item in the array that matches the predicate.
+ Returns the index of the first element in the array that satisfies the provided testing function. Otherwise, it returns `nil`.
- Finds the index of the first item in the array that passes the predicate.
-
- ```lua
- local array = { 1, 2, 3 }
-
- local index = FindWhere(array, function(item, index)
- return item > 1
- end) -- 2
- ```
+ ```lua
+ findWhere({ 1, 2, 3, 4, 5 }, function(value)
+ return value % 2 == 0
+ end) -- 2
+ ```
]=]
local function findWhere(
array: { T },
- predicate: (value: T, index: number, array: { T }) -> any,
+ predicate: (value: T, index: number) -> boolean,
from: number?
): number?
- local length = #array
-
- from = if type(from) == "number" then if from < 1 then length + from else from else 1
+ if from == 0 then
+ from = 1
+ elseif from and from < 0 then
+ from += #array + 1
+ end
- for index = from, #array do
- if predicate(array[index], index, array) then
+ for index = from or 1, #array do
+ if predicate(array[index], index) then
return index
end
end
- return
+ return nil
end
return findWhere
diff --git a/src/Array/findWhereLast.luau b/src/Array/findWhereLast.luau
index aff4c38..d051972 100644
--- a/src/Array/findWhereLast.luau
+++ b/src/Array/findWhereLast.luau
@@ -1,43 +1,32 @@
---!strict
--[=[
- @function findWhereLast
- @within Array
+ @within Array
- @param array {T} -- The array to search.
- @param predicate (value: T, index: number, array: {T}) -> any -- The predicate to use to check the array.
- @param from? number -- The index to start searching from.
- @return number -- The index of the last item in the array that matches the predicate.
+ Returns the index of the last element in the array that satisfies the provided testing function. Otherwise, it returns `nil`.
- Finds the index of the last item in the array that passes the predicate.
-
- ```lua
- local array = { "hello", "world", "hello" }
-
- local index = FindWhereLast(array, function(item, index)
- return item == "hello"
- end) -- 3
-
- local index = FindWhereLast(array, function(item, index)
- return item == "hello"
- end, 2) -- 1
- ```
+ ```lua
+ findWhereLast({ 1, 2, 3, 4, 5 }, function(value)
+ return value % 2 == 0
+ end) -- 4
+ ```
]=]
local function findWhereLast(
array: { T },
- predicate: (value: T, index: number, array: { T }) -> any,
+ predicate: (value: T, index: number) -> boolean,
from: number?
): number?
- local length = #array
-
- from = if type(from) == "number" then if from < 1 then length + from else from else length
+ if from == 0 then
+ from = 1
+ elseif from and from < 0 then
+ from += #array + 1
+ end
- for index = from, 1, -1 do
- if predicate(array[index], index, array) then
+ for index = from or #array, 1, -1 do
+ if predicate(array[index], index) then
return index
end
end
- return
+ return nil
end
return findWhereLast
diff --git a/src/Array/first.luau b/src/Array/first.luau
index 84304b4..b992f48 100644
--- a/src/Array/first.luau
+++ b/src/Array/first.luau
@@ -1,23 +1,16 @@
---!strict
-local At = require(script.Parent.at)
+local at = require("./at")
--[=[
- @function first
- @within Array
+ @within Array
- @param array {T} -- The array to get the first item from.
- @return T -- The first item in the array.
+ Returns the first element of an array.
- Gets the first item in the array.
-
- ```lua
- local array = { 1, 2, 3 }
-
- local value = First(array) -- 1
- ```
+ ```lua
+ first({ "a", "b", "c" }) -- "a"
+ ```
]=]
local function first(array: { T }): T
- return At(array, 1)
+ return at(array, 1)
end
return first
diff --git a/src/Array/flatten.luau b/src/Array/flatten.luau
index cf5b561..88aaa2a 100644
--- a/src/Array/flatten.luau
+++ b/src/Array/flatten.luau
@@ -1,44 +1,37 @@
---!strict
+local INF = newproxy(false)
+
--[=[
- @function flatten
- @within Array
-
- @param array {T} -- The array to flatten.
- @param depth? number -- The depth to flatten the array to.
- @return {T} -- The flattened array.
-
- Flattens an array. If depth is not specified, it will flatten
- the array as far as it can go.
-
- ```lua
- local array = {
- { 1, 2, 3 },
- { 4, 5, 6 },
- { 7, { 8, 9 } },
- }
-
- local new = Flatten(array) -- { 1, 2, 3, 4, 5, 6, 7, 8, 9 }
- local new = Flatten(array, 1) -- { 1, 2, 3, 4, 5, 6, 7, { 8, 9 } }
- ```
+ @within Array
+
+ Flattens an array of arrays into a single array. The `depth` parameter specifies the depth of the flattening. If `depth` is not specified, the array is flattened as much as possible.
+
+ ```lua
+ local array = { 1, { 2, 3, { 4, 5 }}, 6 }
+
+ flatten(array) -- { 1, 2, 3, 4, 5, 6 }
+ flatten(array, 1) -- { 1, 2, 3, { 4, 5 }, 6 }
+ ```
]=]
local function flatten(array: { T }, depth: number?): { T }
- depth = if type(depth) == "number" then depth else math.huge
+ local withDepth = depth or INF
+ local out = {}
- local result = {}
+ for _, value in array do
+ if typeof(value) == "table" and (withDepth == INF or withDepth > 0) then
+ local useDepth = withDepth == INF and INF or withDepth - 1
+ local nested = flatten(value, useDepth)
- for _, value in ipairs(array) do
- if type(value) == "table" and depth > 0 then
- local nested = flatten(value, depth - 1)
-
- for _, nestedValue in ipairs(nested) do
- table.insert(result, nestedValue)
+ for _, nestedValue in nested do
+ table.insert(out, nestedValue)
end
- else
- table.insert(result, value)
+
+ continue
end
+
+ table.insert(out, value)
end
- return result
+ return out
end
return flatten
diff --git a/src/Array/freeze.luau b/src/Array/freeze.luau
index 42963a4..478aebb 100644
--- a/src/Array/freeze.luau
+++ b/src/Array/freeze.luau
@@ -1,30 +1,21 @@
---!strict
-local Copy = require(script.Parent.copy)
+local copy = require("./copy")
--[=[
- @function freeze
- @within Array
+ @within Array
- @param array {T} -- The array to freeze.
- @return {T} -- The frozen array.
+ Returns a shallow copy of the array that is frozen. This means that the array cannot be modified in any way; i.e. it is read-only. Use [Array.freezeDeep] to freeze nested arrays as well.
- Freezes the top level of the array, making it read-only.
+ ```lua
+ local frozen = freeze({ "anna", "elsa", "kristoff" })
- ```lua
- local array = { 1, 2, 3, { 4, 5, 6 } }
-
- local new = Freeze(array)
-
- new[1] = 4 -- error!
- new[4][1] = 7 -- still works!
- ```
+ table.insert(frozen, "olaf") -- error!
+ frozen[4] = "jorgen" -- error!
+ frozen[2] = "sven" -- error!
+ ```
]=]
local function freeze(array: { T }): { T }
- local new = Copy(array)
-
- table.freeze(new)
-
- return new
+ local out = copy(array)
+ return table.freeze(out)
end
return freeze
diff --git a/src/Array/freezeDeep.luau b/src/Array/freezeDeep.luau
index 3b63964..8f3bbed 100644
--- a/src/Array/freezeDeep.luau
+++ b/src/Array/freezeDeep.luau
@@ -1,39 +1,29 @@
---!strict
--[=[
- @function freezeDeep
- @within Array
+ @within Array
- @param array {T} -- The array to freeze.
- @return {T} -- The frozen array.
+ Recursively freezes an array and its nested arrays. Using [Array.freeze] will only freeze the top level of the array, leaving nested arrays mutable.
- Freezes the entire array, making it read-only, including all
- nested arrays.
+ ```lua
+ local frozen = freezeDeep({ 1, 2, { 3, 4, { 5, 6 }}})
- ```lua
- local array = { 1, 2, 3, { 4, 5, 6 } }
-
- local new = FreezeDeep(array)
-
- new[1] = 4 -- error!
- new[4][1] = 7 -- error!
- ```
+ frozen[1] = 2 -- error!
+ frozen[3][1] = 4 -- error!
]=]
local function freezeDeep(array: { T }): { T }
- local result = {}
+ local out: { T } = {}
- for i = 1, #array do
- local value = array[i]
+ for _, value in array do
+ if typeof(value) == "table" then
+ local nested: any = freezeDeep(value)
+ table.insert(out, nested)
- if type(value) == "table" then
- table.insert(result, freezeDeep(value))
- else
- table.insert(result, value)
+ continue
end
- end
- table.freeze(result)
+ table.insert(out, value)
+ end
- return result
+ return table.freeze(out)
end
return freezeDeep
diff --git a/src/Array/includes.luau b/src/Array/includes.luau
index 7683ec9..e63b46d 100644
--- a/src/Array/includes.luau
+++ b/src/Array/includes.luau
@@ -1,32 +1,16 @@
---!strict
-local Find = require(script.Parent.find)
+local find = require("./find")
--[=[
- @function includes
- @within Array
+ @within Array
- @param array {T} -- The array to search.
- @param value any -- The value to search for.
- @param from? number -- The index to start searching from.
- @return boolean -- Whether the array contains the value.
+ Returns `true` if the given value is present in the array, otherwise `false`.
- Checks whether the array contains the value. This is a wrapper
- around `Find`.
-
- #### Aliases
-
- `contains`, `has`
-
- ```lua
- local array = { "hello", "world", "goodbye" }
-
- local value = Includes(array, "hello") -- true
- local value = Includes(array, "sift") -- false
- local value = Includes(array, "hello", 2) -- false
- ```
+ ```lua
+ includes({ "a", "b", "c" }, "b") -- true
+ ```
]=]
-local function includes(array: { T }, value: any, from: number?): boolean
- return Find(array, value, from) ~= nil
+local function includes(array: { T }, value: T, from: number?): boolean
+ return find(array, value, from) ~= nil
end
return includes
diff --git a/src/Array/init.luau b/src/Array/init.luau
index 1fdde97..7d42d9b 100644
--- a/src/Array/init.luau
+++ b/src/Array/init.luau
@@ -1,82 +1,12 @@
---!strict
--[=[
- @class Array
+ @class Array
- An array is a table consisting of index-value pairs. You don't need to
- manually specify the indices when you create an array.
+ An array is a collection of values, each identified by a numeric index. Luau arrays are 1-based, meaning the first element is at index 1, the second element is at index 2, and so on.
- ```lua
- local array = {
- "hello",
- "world",
- }
- ```
-
-
-
- #### Aliases
-
- `List`
+ ```lua
+ local array = { 1, 2, 3 }
+ ```
]=]
-local Array = {
- at = require(script.at),
- concat = require(script.concat),
- concatDeep = require(script.concatDeep),
- copy = require(script.copy),
- copyDeep = require(script.copyDeep),
- count = require(script.count),
- create = require(script.create),
- difference = require(script.difference),
- differenceSymmetric = require(script.differenceSymmetric),
- equals = require(script.equals),
- equalsDeep = require(script.equalsDeep),
- every = require(script.every),
- filter = require(script.filter),
- find = require(script.find),
- findLast = require(script.findLast),
- findWhere = require(script.findWhere),
- findWhereLast = require(script.findWhereLast),
- first = require(script.first),
- flatten = require(script.flatten),
- freeze = require(script.freeze),
- freezeDeep = require(script.freezeDeep),
- includes = require(script.includes),
- insert = require(script.insert),
- is = require(script.is),
- last = require(script.last),
- map = require(script.map),
- pop = require(script.pop),
- push = require(script.push),
- reduce = require(script.reduce),
- reduceRight = require(script.reduceRight),
- removeIndex = require(script.removeIndex),
- removeIndices = require(script.removeIndices),
- removeValue = require(script.removeValue),
- removeValues = require(script.removeValues),
- reverse = require(script.reverse),
- set = require(script.set),
- shift = require(script.shift),
- shuffle = require(script.shuffle),
- slice = require(script.slice),
- some = require(script.some),
- sort = require(script.sort),
- splice = require(script.splice),
- toSet = require(script.toSet),
- unshift = require(script.unshift),
- update = require(script.update),
- zip = require(script.zip),
- zipAll = require(script.zipAll),
-}
-
-Array.join = Array.concat
-Array.merge = Array.concat
-Array.joinDeep = Array.concatDeep
-Array.mergeDeep = Array.concatDeep
-Array.append = Array.push
-Array.prepend = Array.unshift
-Array.indexOf = Array.find
-Array.has = Array.includes
-Array.contains = Array.includes
-Array.isArray = Array.is
+local Array = {}
return Array
diff --git a/src/Array/insert.luau b/src/Array/insert.luau
index 400a129..f6aea5c 100644
--- a/src/Array/insert.luau
+++ b/src/Array/insert.luau
@@ -1,52 +1,31 @@
---!strict
---[=[
- @function insert
- @within Array
-
- @param array {T} -- The array to insert the value into.
- @param index number -- The index to insert the value at (can be negative).
- @param values ...T -- The values to insert.
- @return {T} -- The array with the value inserted.
+local copy = require("./copy")
- Inserts the given values into an array at the given index, shifting all values after it to the right. If the index is negative (or 0), it is counted from the end of the array.
+--[=[
+ @within Array
- If the index to insert at is out of range, the array is not modified.
+ Inserts the given values into the array at the specified index.
- ```lua
- local array = { 1, 2, 3 }
+ ```lua
+ local array = { "a", "b", "c" }
- local newArray = Insert(array, 2, 4) -- { 1, 4, 2, 3 }
- ```
+ insert(array, 2, "x", "y") -- { "a", "x", "y", "b", "c" }
+ insert(array, -1, "x", "y") -- { "a", "b", "x", "y", "c" }
+ ```
]=]
local function insert(array: { T }, index: number, ...: T): { T }
- local length = #array
-
- if index < 1 then
- index += length + 1
+ if index == 0 then
+ index = 1
+ elseif index < 0 then
+ index += #array + 1
end
- if index > length then
- if index > length + 1 then
- return array
- end
-
- index = length + 1
- length += 1
- end
-
- local result = {}
-
- for i = 1, length do
- if i == index then
- for _, value in ipairs({ ... }) do
- table.insert(result, value)
- end
- end
+ local out = copy(array)
- table.insert(result, array[i])
+ for i = 1, select("#", ...) do
+ table.insert(out, index + i - 1, select(i, ...))
end
- return result
+ return out
end
return insert
diff --git a/src/Array/is.luau b/src/Array/is.luau
index 7c8c90b..144895b 100644
--- a/src/Array/is.luau
+++ b/src/Array/is.luau
@@ -1,25 +1,17 @@
---!strict
--[=[
- @function is
- @within Array
+ @within Array
- @param object any -- The object to check.
- @return boolean -- Whether the object is an array.
+ Checks if `value` is an array.
- Checks if the given object is an array.
-
- ```lua
- local array = { 1, 2, 3 }
- local dictionary = { hello = "world" }
- local mixed = { 1, 2, hello = "world" }
-
- Array.is(array) -- true
- Array.is(dictionary) -- false
- Array.is(mixed) -- false
- ```
+ ```lua
+ is({ 1, 2, 3 }) -- true
+ is({ a = 1, b = 2, c = 3 }) -- false
+ is("hello") -- false
+ is({}) -- false
+ ```
]=]
-local function is(object: any): boolean
- return typeof(object) == "table" and #object > 0 and next(object, #object) == nil
+local function is(value: any): boolean
+ return typeof(value) == "table" and #value > 0 and next(value, #value) == nil
end
return is
diff --git a/src/Array/last.luau b/src/Array/last.luau
index 3bd1a2a..10097ff 100644
--- a/src/Array/last.luau
+++ b/src/Array/last.luau
@@ -1,23 +1,16 @@
---!strict
-local At = require(script.Parent.at)
+local at = require("./at")
--[=[
- @function last
- @within Array
+ @within Array
- @param array {T} -- The array to get the last element of.
- @return T -- The last element of the array.
+ Returns the last element of an array.
- Gets the last element of the array.
-
- ```lua
- local array = { 1, 2, 3 }
-
- local value = Last(array) -- 3
- ```
+ ```lua
+ last({ "a", "b", "c" }) --> "c"
+ ```
]=]
local function last(array: { T }): T
- return At(array, 0)
+ return at(array, -1)
end
return last
diff --git a/src/Array/map.luau b/src/Array/map.luau
index f9bdb18..d48a1ad 100644
--- a/src/Array/map.luau
+++ b/src/Array/map.luau
@@ -1,34 +1,28 @@
---!strict
---[=[
- @function map
- @within Array
-
- @param array {T} -- The array to map.
- @param mapper (value: T, index: number, array: {T}) -> U? -- The mapper function.
- @return {U} -- The mapped array.
+local None = require("@Sift/None")
- Maps the array using the mapper function.
+--[=[
+ @within Array
- ```lua
- local array = { 1, 2, 3 }
+ Processes each element of an array with a mapper function and returns a new array with the results.
- local new = Map(array, function(value, index)
- return value * 2
- end) -- { 2, 4, 6 }
- ```
+ ```lua
+ map({ 1, 2, 3, 4, 5 }, function(value)
+ return value * 2
+ end) -- { 2, 4, 6, 8, 10 }
+ ```
]=]
-local function map(array: { T }, mapper: (value: T, index: number, array: { T }) -> U?): { U }
- local mapped = {}
+local function map(array: { T }, mapper: (value: T, index: number) -> U?): { U }
+ local out: { U } = {}
- for index, value in ipairs(array) do
- local mappedValue = mapper(value, index, array)
+ for index, value in array do
+ local mapped = mapper(value, index)
- if mappedValue ~= nil then
- table.insert(mapped, mappedValue)
+ if mapped ~= nil and mapped ~= None then
+ table.insert(out, mapped)
end
end
- return mapped
+ return out
end
return map
diff --git a/src/Array/partition.luau b/src/Array/partition.luau
new file mode 100644
index 0000000..9a9f8a0
--- /dev/null
+++ b/src/Array/partition.luau
@@ -0,0 +1,30 @@
+--[=[
+ @within Array
+
+ Filters an array into two arrays based on a filter function. The first array contains all elements that pass the filter, and the second array contains all elements that fail the filter.
+
+ ```lua
+ local even, odd = partition({ 1, 2, 3, 4, 5 }, function(value)
+ return value % 2 == 0
+ end)
+
+ -- even: { 2, 4 }
+ -- odd: { 1, 3, 5 }
+ ```
+]=]
+local function partition(array: { T }, filterer: (value: T, index: number) -> boolean)
+ local pass = {}
+ local fail = {}
+
+ for index, value in array do
+ if filterer(value, index) then
+ table.insert(pass, value)
+ else
+ table.insert(fail, value)
+ end
+ end
+
+ return pass, fail
+end
+
+return partition
diff --git a/src/Array/pop.luau b/src/Array/pop.luau
index 7a42515..c22ee80 100644
--- a/src/Array/pop.luau
+++ b/src/Array/pop.luau
@@ -1,33 +1,30 @@
---!strict
---[=[
- @function pop
- @within Array
+local removeIndices = require("./removeIndices")
- @param array {T} -- The array to pop an element from.
- @param count? number = 1 -- The number of elements to pop.
- @return {T} -- An array with the popped elements removed.
+--[=[
+ @within Array
- Removes an element from the end of the array, and returns
- the array with the popped elements removed.
+ Returns a new array with the last `count` elements removed. If `count` is not provided, it defaults to `1`.
- ```lua
- local array = { 1, 2, 3 }
+ ```lua
+ local array = { 1, 2, 3, 4, 5 }
- local new = Pop(array) -- { 1, 2 }
- local new = Pop(array, 2) -- { 1 }
- ```
+ pop(array) -- { 1, 2, 3, 4 }
+ pop(array, 3) -- { 1, 2 }
+ ```
]=]
local function pop(array: { T }, count: number?): { T }
- local length = #array
- local result = {}
+ local useCount = count or 1
+ local indices = {}
- count = if type(count) == "number" then count else 1
+ if useCount > #array then
+ return {}
+ end
- for i = 1, length - count do
- table.insert(result, array[i])
+ for index = 1, useCount do
+ table.insert(indices, #array - index + 1)
end
- return result
+ return removeIndices(array, table.unpack(indices))
end
return pop
diff --git a/src/Array/push.luau b/src/Array/push.luau
index 707d41e..bffe75b 100644
--- a/src/Array/push.luau
+++ b/src/Array/push.luau
@@ -1,36 +1,16 @@
---!strict
---[=[
- @function push
- @within Array
-
- @param array {T} -- The array to push an element to.
- @param ... ...T -- The elements to push.
- @return {T} -- The array with the pushed elements.
-
- Adds elements to the end of the array.
-
- #### Aliases
+local insert = require("./insert")
- `append`
+--[=[
+ @within Array
- ```lua
- local array = { 1, 2, 3 }
+ Returns a new array with the provided values appended to the end.
- local new = Push(array, 4, 5, 6) -- { 1, 2, 3, 4, 5, 6 }
- ```
+ ```lua
+ push({ 1, 2, 3 }, 4, 5) -- {1, 2, 3, 4, 5}
+ ```
]=]
local function push(array: { T }, ...: T): { T }
- local result = {}
-
- for _, value in ipairs(array) do
- table.insert(result, value)
- end
-
- for _, value in ipairs({ ... }) do
- table.insert(result, value)
- end
-
- return result
+ return insert(array, #array + 1, ...)
end
return push
diff --git a/src/Array/reduce.luau b/src/Array/reduce.luau
index d0bfb5e..554019b 100644
--- a/src/Array/reduce.luau
+++ b/src/Array/reduce.luau
@@ -1,47 +1,34 @@
---!strict
---[=[
- @function reduce
- @within Array
-
- @param array {T} -- The array to reduce.
- @param reducer (accumulator: U, value: T, index: number, array: {T}) -> U -- The reducer to use.
- @param initialReduction? U = {T}[1] -- The initial accumulator value.
- @return U -- The final accumulator value.
+local None = require("@Sift/None")
- Reduces the array using the given reducer and initial accumulator value.
- If no `initialReduction` value is given, the first item in the array is used.
-
- ```lua
- local array = { 1, 2, 3 }
+--[=[
+ @within Array
- local value = Reduce(array, function(accumulator, item, index)
- return accumulator - item
- end) -- -4
+ Reduces an array to a single value using a reducer function.
- local value = Reduce(array, function(accumulator, item, index)
- table.insert(accumulator, item)
- return accumulator
- end, {}) -- { 1, 2, 3 }
- ```
+ ```lua
+ reduce({ 1, 2, 3 }, function(accumulator, value)
+ return accumulator + value
+ end) -- 6
+ ```
]=]
local function reduce(
array: { T },
- reducer: (accumulator: U, value: T, index: number, array: { T }) -> U,
- initReduction: U?
+ reducer: (accumulator: U, value: T, index: number) -> U,
+ initAccumulator: U?
): U
- local result = initReduction
+ local out = initAccumulator :: U
local start = 1
- if result == nil then
- result = array[1]
+ if out == nil or out == None then
+ out = array[1] :: any
start = 2
end
for index = start, #array do
- result = reducer(result, array[index], index, array)
+ out = reducer(out, array[index], index)
end
- return result
+ return out
end
return reduce
diff --git a/src/Array/reduceRight.luau b/src/Array/reduceRight.luau
index 7d79e77..f39620b 100644
--- a/src/Array/reduceRight.luau
+++ b/src/Array/reduceRight.luau
@@ -1,48 +1,34 @@
---!strict
---[=[
- @function reduceRight
- @within Array
-
- @param array {T} -- The array to reduce.
- @param reducer (accumulator: U, value: T, index: number, array: {T}) -> U -- The reducer to use.
- @param initialReduction? U = {T}[#{T}] -- The initial accumulator value.
- @return U -- The final accumulator value.
+local None = require("@Sift/None")
- Reduces the array using the given reducer and initial accumulator value,
- starting from the end of the array. If no `initialReduction` value is given,
- the last item in the array is used.
-
- ```lua
- local array = { 1, 2, 3 }
+--[=[
+ @within Array
- local value = ReduceRight(array, function(accumulator, item, index)
- return accumulator - item
- end) -- 0
+ Reduces an array into a single value from end to start.
- local value = ReduceRight(array, function(accumulator, item, index)
- table.insert(accumulator, item)
- return accumulator
- end, {}) -- { 3, 2, 1 }
- ```
+ ```lua
+ reduceRight({ 1, 2, 3 }, function(accumulator, value)
+ return accumulator - value
+ end) -- 0
+ ```
]=]
local function reduceRight(
array: { T },
- reducer: (accumulator: U, value: T, index: number, array: { T }) -> U,
- initReduction: U?
+ reducer: (accumulator: U, value: T, index: number) -> U,
+ initAccumulator: U?
): U
- local result = initReduction
+ local out = initAccumulator :: U
local start = #array
- if result == nil then
- result = array[start]
+ if out == nil or out == None then
+ out = array[start] :: any
start -= 1
end
for index = start, 1, -1 do
- result = reducer(result, array[index], index, array)
+ out = reducer(out, array[index], index)
end
- return result
+ return out
end
return reduceRight
diff --git a/src/Array/removeIndex.luau b/src/Array/removeIndex.luau
index c98a8cc..a7cbabc 100644
--- a/src/Array/removeIndex.luau
+++ b/src/Array/removeIndex.luau
@@ -1,36 +1,16 @@
---!strict
---[=[
- @function removeIndex
- @within Array
-
- @param array {T} -- The array to remove the value from.
- @param index number -- The index to remove the value from (can be negative).
- @return {T} -- The array with the value removed.
+local removeIndices = require("./removeIndices")
- Removes a value from an array at the given index.
+--[=[
+ @within Array
- ```lua
- local array = { 1, 2, 3 }
+ Returns a new array with the element at the specified index removed.
- local new = RemoveIndex(array, 1) -- { 2, 3 }
- local new = RemoveIndex(array, -1) -- { 1, 3 }
- ```
+ ```lua
+ removeIndex({ 1, 2, 3 }, 2) -- {1, 3}
+ ```
]=]
local function removeIndex(array: { T }, index: number): { T }
- local length = #array
- local result = {}
-
- if index < 1 then
- index += length
- end
-
- for arrIndex, value in ipairs(array) do
- if arrIndex ~= index then
- table.insert(result, value)
- end
- end
-
- return result
+ return removeIndices(array, index)
end
return removeIndex
diff --git a/src/Array/removeIndices.luau b/src/Array/removeIndices.luau
index 8a6f8c8..f3bb844 100644
--- a/src/Array/removeIndices.luau
+++ b/src/Array/removeIndices.luau
@@ -1,41 +1,36 @@
---!strict
---[=[
- @function removeIndices
- @within Array
-
- @param array {T} -- The array to remove the indices from.
- @param ... ...number -- The indices to remove the values from (can be negative).
- @return {T} -- The array with the values removed.
+local reduce = require("./reduce")
- Removes values from an array at the given indices.
+--[=[
+ @within Array
- ```lua
- local array = { 1, 2, 3 }
+ Returns a new array with the elements at the specified indices removed.
- local new = RemoveIndices(array, 1, 2) -- { 3 }
- local new = RemoveIndices(array, 0, -1) -- { 1 }
- ```
+ ```lua
+ removeIndices({ 1, 2, 3, 4, 5 }, 2, 4) -- {1, 3, 5}
+ ```
]=]
local function removeIndices(array: { T }, ...: number): { T }
- local length = #array
- local indices = {}
- local result = {}
-
- for _, index in ipairs({ ... }) do
- if index < 1 then
- index += length
+ local indices = reduce({ ... }, function(acc, value)
+ if value == 0 then
+ value = 1
+ elseif value < 0 then
+ value += #array + 1
end
- indices[index] = true
- end
+ acc[value] = true
+
+ return acc
+ end, {})
+
+ local out = {}
- for index, value in ipairs(array) do
+ for index, value in array do
if not indices[index] then
- table.insert(result, value)
+ table.insert(out, value)
end
end
- return result
+ return out
end
return removeIndices
diff --git a/src/Array/removeValue.luau b/src/Array/removeValue.luau
index 390c22a..d3b191e 100644
--- a/src/Array/removeValue.luau
+++ b/src/Array/removeValue.luau
@@ -1,30 +1,16 @@
---!strict
---[=[
- @function removeValue
- @within Array
-
- @param array {T} -- The array to remove the value from.
- @param value T -- The value to remove.
- @return {T} -- The array with the value removed.
+local removeValues = require("./removeValues")
- Removes a value from an array.
+--[=[
+ @within Array
- ```lua
- local array = { 1, 2, 3 }
+ Removes all instances of a value from an array.
- local new = RemoveValue(array, 2) -- { 1, 3 }
- ```
+ ```lua
+ removeValue({ "a", "b", "c", "a" }, "a") -- { "b", "c" }
+ ```
]=]
local function removeValue(array: { T }, value: T): { T }
- local result = {}
-
- for _, arrValue in ipairs(array) do
- if arrValue ~= value then
- table.insert(result, arrValue)
- end
- end
-
- return result
+ return removeValues(array, value)
end
return removeValue
diff --git a/src/Array/removeValues.luau b/src/Array/removeValues.luau
index 4a6928e..644b777 100644
--- a/src/Array/removeValues.luau
+++ b/src/Array/removeValues.luau
@@ -1,33 +1,25 @@
---!strict
-local ToSet = require(script.Parent.toSet)
+local filter = require("./filter")
+local reduce = require("./reduce")
--[=[
- @function removeValues
- @within Array
+ @within Array
- @param array {T} -- The array to remove values from.
- @param ... T -- The values to remove.
- @return {T} -- The array with the values removed.
+ Removes all instances of the given values from the array.
- Removes values from an array.
-
- ```lua
- local array = { "a", "b", "c", "c", "d", "e" }
-
- local new = RemoveValues(array, "c", "d") -- { "a", "b", "e" }
- ```
+ ```lua
+ removeValues({ "a", "a", "c", "b", "c", "a", "d" }, "a", "c")
+ -- { "b", "d" }
+ ```
]=]
local function removeValues(array: { T }, ...: T): { T }
- local valueSet = ToSet({ ... })
- local result = {}
-
- for _, value in ipairs(array) do
- if not valueSet[value] then
- table.insert(result, value)
- end
- end
-
- return result
+ local values = reduce({ ... }, function(acc, value)
+ acc[value] = true
+ return acc
+ end, {})
+
+ return filter(array, function(value)
+ return not values[value]
+ end)
end
return removeValues
diff --git a/src/Array/reverse.luau b/src/Array/reverse.luau
index 192be65..64db68d 100644
--- a/src/Array/reverse.luau
+++ b/src/Array/reverse.luau
@@ -1,27 +1,20 @@
---!strict
--[=[
- @function reverse
- @within Array
+ @within Array
- @param array {T} -- The array to reverse.
- @return {T} -- The reversed array.
+ Returns a new array with the elements in reverse order.
- Reverses the order of the items in an array.
-
- ```lua
- local array = { 1, 2, 3 }
-
- local new = Reverse(array) -- { 3, 2, 1 }
- ```
+ ```lua
+ reverse({ "a", "b", "c" }) -- { "c", "b", "a" }
+ ```
]=]
local function reverse(array: { T }): { T }
- local result = {}
+ local out = {}
for index = #array, 1, -1 do
- table.insert(result, array[index])
+ table.insert(out, array[index])
end
- return result
+ return out
end
return reverse
diff --git a/src/Array/set.luau b/src/Array/set.luau
index 51b26d6..d8366b8 100644
--- a/src/Array/set.luau
+++ b/src/Array/set.luau
@@ -1,39 +1,29 @@
---!strict
---[=[
- @function set
- @within Array
+local copy = require("./copy")
- @param array {T} -- The array to set the value on.
- @param index number -- The index to set the value at (can be negative).
- @param value T -- The value to set.
- @return {T} -- The array with the value set.
+--[=[
+ @within Array
- Sets a value on an array at the given index.
+ Sets the value at the given index in the array and returns a new array.
- ```lua
- local array = { 1, 2, 3 }
+ ```lua
+ local array = { "a", "b", "c", "d" }
- local new = Set(array, 2, 4) -- { 1, 4, 3 }
- local new = Set(array, -1, 4) -- { 1, 2, 4 }
- ```
+ set(array, 2, "z") -- { "a", "z", "c", "d" }
+ set(array, -1, "x") -- { "a", "b", "c", "x" }
+ ```
]=]
-local function set(array: { T }, index: number, value: T?): { T }
- local length = #array
- local result = {}
+local function set(array: { T }, index: number, value: T): { T }
+ local out = copy(array)
- if index < 1 then
- index += length
+ if index == 0 then
+ index = 1
+ elseif index < 0 then
+ index += #out + 1
end
- for arrIndex, arrValue in ipairs(array) do
- if arrIndex == index then
- table.insert(result, value)
- else
- table.insert(result, arrValue)
- end
- end
+ out[index] = value
- return result
+ return out
end
return set
diff --git a/src/Array/shift.luau b/src/Array/shift.luau
index 0c55fe6..4858541 100644
--- a/src/Array/shift.luau
+++ b/src/Array/shift.luau
@@ -1,33 +1,30 @@
---!strict
---[=[
- @function shift
- @within Array
+local removeIndices = require("./removeIndices")
- @param array {T} -- The array to shift.
- @param count? number -- The number of items to shift.
- @return {T} -- The shifted array.
+--[=[
+ @within Array
- Removes the first item from an array and returns the array
- with the item removed.
+ Returns a new array with the first `count` elements removed. If `count` is not provided, it defaults to `1`.
- ```lua
- local array = { 1, 2, 3 }
+ ```lua
+ local array = { "a", "b", "c", "d" }
- local new = Shift(array) -- { 2, 3 }
- local new = Shift(array, 2) -- { 3 }
- ```
+ shift(array) -- { "b", "c", "d" }
+ shift(array, 2) -- { "c", "d" }
+ ```
]=]
local function shift(array: { T }, count: number?): { T }
- local length = #array
- local result = {}
+ local useCount = count or 1
+ local indices = {}
- count = if type(count) == "number" then count + 1 else 2
+ if useCount > #array then
+ return {}
+ end
- for i = count, length do
- table.insert(result, array[i])
+ for index = #array, useCount, -1 do
+ table.insert(indices, index)
end
- return result
+ return removeIndices(array, table.unpack(indices))
end
return shift
diff --git a/src/Array/shuffle.luau b/src/Array/shuffle.luau
index e237d42..d339e3f 100644
--- a/src/Array/shuffle.luau
+++ b/src/Array/shuffle.luau
@@ -1,34 +1,28 @@
---!strict
-local Copy = require(script.Parent.copy)
+local copy = require("./copy")
--[=[
- @function shuffle
- @within Array
+ @within Array
- @param array {T} -- The array to shuffle.
- @return {T} -- The shuffled array.
+ Copies an array with a randomized order.
- Randomises the order of the items in an array.
-
- ```lua
- local array = { 1, 2, 3 }
-
- local new = Shuffle(array) -- { 2, 3, 1 }
- ```
+ ```lua
+ shuffle({ "a", "b", "c" }) -- { "c", "a", "b" }
+ ```
]=]
-local function shuffle(array: { T }): { T }
- local random = Random.new(os.time() * #array)
- local result = Copy(array)
+local function shuffle(array: { T }, seed: number?): { T }
+ math.randomseed(seed or os.clock() * #array)
+
+ local out = copy(array)
- for index = #result, 1, -1 do
- local randomIndex = random:NextInteger(1, index)
- local temp = result[index]
+ for index = #out, 1, -1 do
+ local randomIndex = math.random(1, index)
+ local temp = out[index]
- result[index] = result[randomIndex]
- result[randomIndex] = temp
+ out[index] = out[randomIndex]
+ out[randomIndex] = temp
end
- return result
+ return out
end
return shuffle
diff --git a/src/Array/slice.luau b/src/Array/slice.luau
index 7d6c20e..14b872f 100644
--- a/src/Array/slice.luau
+++ b/src/Array/slice.luau
@@ -1,43 +1,39 @@
---!strict
--[=[
- @function slice
- @within Array
+ @within Array
- @param array {T} -- The array to slice.
- @param from? number -- The index to start from (can be negative).
- @param to? number -- The index to end at (can be negative).
- @return {T} -- The sliced array.
+ Returns a slice of an array from `from` to `to` (inclusive). `from` and `to` can be negative, in which case they will be treated as an offset from the end of the array.
- Slices an array.
+ ```lua
+ local array = { "a", "b", "c", "d", "e", "f" }
- ```lua
- local array = { 1, 2, 3, 4, 5 }
-
- local new = Slice(array, 2, 3) -- { 2, 3 }
- local new = Slice(array, -2, -1) -- { 3, 4 }
- local new = Slice(array, 3) -- { 3, 4, 5 }
- ```
+ slice(array, 2, 4) -- { "b", "c", "d" }
+ slice(array, 2, -2) -- { "b", "c", "d", "e" }
+ ```
]=]
local function slice(array: { T }, from: number?, to: number?): { T }
- local length = #array
- local result = {}
-
- from = if type(from) == "number" then from else 1
- to = if type(to) == "number" then to else length
+ if not from or from == 0 then
+ from = 1
+ elseif from < 0 then
+ from += #array + 1
+ end
- if from < 1 then
- from += length
+ if not to or to == 0 then
+ to = #array
+ elseif to < 0 then
+ to += #array + 1
end
- if to < 1 then
- to += length
+ if from == to then
+ return {}
end
- for i = from, to do
- table.insert(result, array[i])
+ local out = {}
+
+ for index = from :: number, to :: number do
+ table.insert(out, array[index])
end
- return result
+ return out
end
return slice
diff --git a/src/Array/some.luau b/src/Array/some.luau
index 0c5be36..d456e98 100644
--- a/src/Array/some.luau
+++ b/src/Array/some.luau
@@ -1,32 +1,17 @@
---!strict
--[=[
- @function some
- @within Array
+ @within Array
- @param array {T} -- The array to check.
- @param predicate (value: T, index: number, array: {T}) -> any -- The predicate to use to check the array.
- @return boolean -- Whether some item in the array passes the predicate.
+ Returns `true` if at least one element in the array satisfies the provided testing function. Otherwise, `false` is returned.
- Checks whether some item in the array passes the predicate.
-
- ```lua
- local array = { 1, 2, 3 }
-
- local value = Some(array, function(item, index)
- return item > 1
- end) -- true
-
- local value = Some(array, function(item, index)
- return item > 3
- end) -- false
- ```
+ ```lua
+ some({ 1, 2, 3, 4, 5 }, function(value)
+ return value % 2 == 0
+ end) -- true
+ ```
]=]
-local function some(
- array: { T },
- predicate: (value: T, index: number, array: { T }) -> any
-): boolean
- for index, value in ipairs(array) do
- if predicate(value, index, array) then
+local function some(array: { T }, predicate: (value: T, index: number) -> boolean): boolean
+ for index, value in array do
+ if predicate(value, index) then
return true
end
end
diff --git a/src/Array/sort.luau b/src/Array/sort.luau
index 72c6833..e81b552 100644
--- a/src/Array/sort.luau
+++ b/src/Array/sort.luau
@@ -1,28 +1,18 @@
---!strict
-local Copy = require(script.Parent.copy)
+local copy = require("./copy")
--[=[
- @function sort
- @within Array
+ @within Array
- @param array {T} -- The array to sort.
- @param comparator? (a: T, b: T) -> boolean -- The comparator function.
- @return {T} -- The sorted array.
+ Returns a new array with the elements sorted. The optional `comparer` function is used to compare elements. If not provided, the default comparer will be used (ascending order).
- Sorts an array.
-
- ```lua
- local array = { "a", "b", "c", "d", "e" }
-
- local new = Sort(array, function(a, b)
- return a > b
- end) -- { "e", "d", "c", "b", "a" }
- ```
+ ```lua
+ sort({ 3, 1, 2 }) -- { 1, 2, 3 }
+ sort({ "c", "a", "b" }) -- { "a", "b", "c" }
+ ```
]=]
-local function sort(array: { T }, comparator: ((firstValue: T, secondValue: T) -> boolean)?): { T }
- local result = Copy(array)
-
- table.sort(result, comparator)
+local function sort(array: { T }, comparer: ((a: T, b: T) -> boolean)?): { T }
+ local result = copy(array)
+ table.sort(result, comparer)
return result
end
diff --git a/src/Array/splice.luau b/src/Array/splice.luau
index e0c4a22..8497dd3 100644
--- a/src/Array/splice.luau
+++ b/src/Array/splice.luau
@@ -1,52 +1,44 @@
---!strict
--[=[
- @function splice
- @within Array
+ @within Array
- @param array {T} -- The array to splice.
- @param start? number -- The index to start splicing at (can be negative).
- @param end? number -- The index to end splicing at (can be negative).
- @param ... ...T -- The values to insert.
- @return {T} -- The spliced array.
+ Returns a new array with elements removed and/or added. The `at` parameter specifies the index at which to start removing or adding elements. The `replaceCount` parameter specifies the number of elements to remove. Finally, the rest of the parameters are the elements to add to the array.
- Splices an array.
+ ```lua
+ local array = { "a", "b", "c", "d" }
- ```lua
- local array = { 1, 2, 3, 4, 5 }
-
- local new = Splice(array, 3, 4, 6, 7) -- { 1, 2, 6, 7, 4, 5 }
- local new = Splice(array, -1, 0, 6, 7) -- { 1, 2, 3, 4, 6, 7 }
- local new = Splice(array, 4, -1, 6, 7) -- { 1, 2, 3, 6, 7, 5 }
- ```
+ splice(array, 2, 1, "x", "y", "z") -- { "a", "x", "y", "z", "c", "d" }
+ splice(array, 2, 0, "x", "y", "z") -- { "a", "x", "y", "z", "b", "c", "d" }
+ splice(array, 2, 1) -- { "a", "c", "d" }
+ ```
]=]
-local function splice(array: { T }, from: number?, to: number?, ...: T?): { T }
- local length = #array
- local result = {}
-
- from = if type(from) == "number" then from else 1
- to = if type(to) == "number" then to else length
+local function splice(array: { T }, at: number?, replaceCount: number?, ...: T?): { T }
+ local useAt, useReplaceCount = 0, 0
- if from < 1 then
- from += length
+ if not at or at == 0 then
+ useAt = 1
+ elseif at < 0 then
+ useAt = at + #array + 1
end
- if to < 1 then
- to += length
+ if not replaceCount or replaceCount < 0 then
+ useReplaceCount = 0
end
- for index = 1, from - 1 do
- table.insert(result, array[index])
+ local out = {}
+
+ for index = 1, useAt - 1 do
+ table.insert(out, array[index])
end
- for _, value in ipairs({ ... }) do
- table.insert(result, value)
+ for index = 1, select("#", ...) do
+ table.insert(out, select(index, ...))
end
- for index = to + 1, length do
- table.insert(result, array[index])
+ for index = useAt + useReplaceCount, #array do
+ table.insert(out, array[index])
end
- return result
+ return out
end
return splice
diff --git a/src/Array/toSet.luau b/src/Array/toSet.luau
index 205774e..bd2ebe1 100644
--- a/src/Array/toSet.luau
+++ b/src/Array/toSet.luau
@@ -1,30 +1,20 @@
---!strict
-local Sift = script.Parent.Parent
-local _T = require(Sift.Types)
+local reduce = require("./reduce")
--[=[
- @function toSet
- @within Array
+ @within Array
- @param array {T} -- The array to convert to a set.
- @return Set -- The set.
+ Converts an array into a set, where each value in the array is a key in the set, and the value is `true`.
- Converts an array to a set.
-
- ```lua
- local array = { "a", "b", "b", "c", "d" }
-
- local set = ToSet(array) -- { a = true, b = true, c = true, d = true }
- ```
+ ```lua
+ toSet({ "a", "b", "c", "a", "a", "d" })
+ -- { a = true, b = true, c = true, d = true }
+ ```
]=]
-local function toSet(array: { T }): _T.Set
- local set = {}
-
- for _, value in ipairs(array) do
+local function toSet(array: { T }): { [T]: boolean }
+ return reduce(array, function(set, value)
set[value] = true
- end
-
- return set
+ return set
+ end, {})
end
return toSet
diff --git a/src/Array/unshift.luau b/src/Array/unshift.luau
index 9e453a2..3cbdf76 100644
--- a/src/Array/unshift.luau
+++ b/src/Array/unshift.luau
@@ -1,32 +1,10 @@
---!strict
---[=[
- @function unshift
- @within Array
-
- @param array {T} -- The array to insert the values to.
- @param ... ...T -- The values to insert.
- @return {T} -- The array with the values inserted.
-
- Inserts values to the beginning of an array.
-
- #### Aliases
-
- `prepend`
+local insert = require("./insert")
- ```lua
- local array = { 1, 2, 3 }
-
- local new = Unshift(array, 4, 5) -- { 4, 5, 1, 2, 3 }
- ```
+--[=[
+ @within Array
]=]
local function unshift(array: { T }, ...: T): { T }
- local result = { ... }
-
- for _, value in ipairs(array) do
- table.insert(result, value)
- end
-
- return result
+ return insert(array, 1, ...)
end
return unshift
diff --git a/src/Array/update.luau b/src/Array/update.luau
index e3e96da..0aac09c 100644
--- a/src/Array/update.luau
+++ b/src/Array/update.luau
@@ -1,68 +1,43 @@
---!strict
-local Sift = script.Parent.Parent
+local None = require("@Sift/None")
+local Util = require("@Sift/Util")
-local Util = require(Sift.Util)
-local Copy = require(script.Parent.copy)
-
-type Callback = (index: number) -> T
-type Updater = (currentValue: T, index: number) -> T
-
-local function call(callback: Callback, index: number)
- if type(callback) == "function" then
- return callback(index)
- end
-end
+local copy = require("./copy")
--[=[
- @function update
- @within Array
-
- @param array {T} -- The array to update.
- @param index number -- The index to update.
- @param updater? (value: T, index: number) -> T -- The updater function.
- @param callback? (index: number) -> T -- The callback function.
- @return {T} -- The updated array.
+ @within Array
- Updates an array at the given index. If the value at the given index does
- not exist, `callback` will be called, and its return value will be used
- as the value at the given index.
+ Updates the value at the given index in the array. If the value at the given index is `nil` or `None`, the `adder` function will be called to add a new value to the array. If the value at the given index is not `nil` or `None`, the `updater` function will be called to update the value at the given index.
- ```lua
- local array = { 1, 2, 3 }
+ ```lua
+ local array = { "a", "b", "c" }
- local new = Update(array, 2, function(value)
- return value + 1
- end) -- { 2, 3, 3 }
+ update(array, 2, function(value, index)
+ return value .. "!"
+ }) -- { "a", "b!", "c" }
- local new = Update(array, 4, function(value)
- return value + 1
- end, function(value)
- return 10
- end) -- { 1, 2, 3, 10 }
- ```
+ update(array, 4, nil, function(index)
+ return "d"
+ }) -- { "a", "b", "c", "d" }
+ ```
]=]
local function update(
array: { T },
index: number,
- updater: Updater?,
- callback: Callback?
+ updater: ((value: T, index: number) -> T)?,
+ adder: ((index: number) -> T)?
): { T }
- local length = #array
- local result = Copy(array)
+ local out = copy(array)
+ index = Util.normalizeIndex(index, #array)
- if index < 1 then
- index += length
+ if updater and out[index] ~= nil and out[index] ~= None then
+ out[index] = updater(out[index], index)
end
- updater = if type(updater) == "function" then updater else Util.func.returned
-
- if result[index] ~= nil then
- result[index] = updater(result[index], index)
- else
- result[index] = call(callback, index)
+ if adder and (out[index] == nil or out[index] == None) then
+ out[index] = adder(index)
end
- return result
+ return out
end
return update
diff --git a/src/Array/zip.luau b/src/Array/zip.luau
index c30f3ec..2ebee7f 100644
--- a/src/Array/zip.luau
+++ b/src/Array/zip.luau
@@ -1,47 +1,41 @@
---!strict
-local Reduce = require(script.Parent.reduce)
+local reduce = require("./reduce")
--[=[
- @function zip
- @within Array
+ @within Array
- @param ... {any} -- The arrays to zip together.
- @return {any} -- The zipped array.
+ Links together the values of multiple arrays into a single array of arrays, where each index of the new array contains the values of the original arrays at that index. If the arrays are of different lengths, the new array will be the length of the shortest array.
- Zips multiple arrays together into a single array.
+ ```lua
+ local array1 = { "a", "b", "c", "d" }
+ local array2 = { 1, 2, 3 }
- ```lua
- local table1 = { 1, 2, 3 }
- local table2 = { "hello", "world", "goodbye" }
-
- local new = Zip(table1, table2) -- { { 1, "hello" }, { 2, "world" }, { 3, "goodbye" } }
- ```
+ zip(array1, array2)
+ -- { { "a", 1 }, { "b", 2 }, { "c", 3 } }
+ ```
]=]
-local function zip(...: { any }): T
- local argCount = select("#", ...)
- local arguments = { ... }
-
- local result = {}
-
- if argCount == 0 then
- return result
+local function zip(...: { any }): { { any } }
+ if select("#", ...) == 0 then
+ return {}
end
- local minLength: number = Reduce(arguments, function(acc, val)
- return math.min(acc, #val)
- end, #arguments[1])
+ local arrays = { ... }
+ local length = reduce(arrays, function(acc, array)
+ return math.min(acc, #array)
+ end, math.huge)
+
+ local out = {}
- for index = 1, minLength do
+ for index = 1, length do
local values = {}
- for _, argArray in ipairs(arguments) do
- table.insert(values, argArray[index])
+ for _, array in arrays do
+ table.insert(values, array[index])
end
- table.insert(result, values)
+ table.insert(out, values)
end
- return result
+ return out
end
return zip
diff --git a/src/Array/zipAll.luau b/src/Array/zipAll.luau
index 33612a2..6050316 100644
--- a/src/Array/zipAll.luau
+++ b/src/Array/zipAll.luau
@@ -1,51 +1,43 @@
---!strict
-local Sift = script.Parent.Parent
-
-local Reduce = require(script.Parent.reduce)
-local None = require(Sift.None)
+local None = require("@Sift/None")
+local reduce = require("./reduce")
--[=[
- @function zipAll
- @within Array
-
- @param ... ...{any} -- The arrays to zip.
- @return {any} -- The zipped array.
+ @within Array
- Zips multiple arrays together into a single array, filling
- in missing values with `None`.
+ Links together the values of multiple arrays into a single array of arrays, where each index of the new array contains the values of the original arrays at that index. If the arrays are of different lengths, the shorter arrays will be padded with `None`.
- ```lua
- local table1 = { 1, 2, 3, 4 }
- local table2 = { "hello", "world", "goodbye" }
+ ```lua
+ local array1 = { 1, 2, 3 }
+ local array2 = { "a", "b", "c", "d" }
- local new = ZipAll(table1, table2) -- { { 1, "hello" }, { 2, "world" }, { 3, "goodbye" }, { 4, None } }
- ```
+ zipAll(array1, array2)
+ -- { { 1, "a" }, { 2, "b" }, { 3, "c" }, { None, "d" } }
+ ```
]=]
-local function zipAll(...: { any }): T
- local argCount = select("#", ...)
- local arguments = { ... }
- local result = {}
-
- if argCount == 0 then
- return result
+local function zipAll(...: { any }): { { any } }
+ if select("#", ...) == 0 then
+ return {}
end
- local maxLength = Reduce(arguments, function(acc, val)
- return math.max(acc, #val)
- end, #arguments[1])
+ local arrays = { ... }
+ local length = reduce(arrays, function(acc, array)
+ return math.max(acc, #array)
+ end, 0)
+
+ local out = {}
- for index = 1, maxLength do
+ for i = 1, length do
local values = {}
- for _, argArray in ipairs(arguments) do
- local value = argArray[index]
- table.insert(values, if value == nil then None else value)
+ for _, array in arrays do
+ local value = if array[i] == nil then None else array[i]
+ table.insert(values, value)
end
- table.insert(result, values)
+ table.insert(out, values)
end
- return result
+ return out
end
return zipAll
diff --git a/src/Dictionary/copy.luau b/src/Dictionary/copy.luau
deleted file mode 100644
index 60c30aa..0000000
--- a/src/Dictionary/copy.luau
+++ /dev/null
@@ -1,20 +0,0 @@
---!strict
---[=[
- @function copy
- @within Dictionary
-
- @param dictionary T -- The dictionary to copy.
- @return T -- The copied dictionary.
-
- Copies a dictionary.
-
- ```lua
- local dictionary = { hello = "world" }
-
- local new = Copy(dictionary) -- { hello = "world" }
-
- print(new == dictionary) -- false
- print(new.hello == dictionary.hello) -- true
- ```
-]=]
-return table.clone
diff --git a/src/Dictionary/copy.luau.todo b/src/Dictionary/copy.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/copyDeep.luau b/src/Dictionary/copyDeep.luau
deleted file mode 100644
index 5734f51..0000000
--- a/src/Dictionary/copyDeep.luau
+++ /dev/null
@@ -1,32 +0,0 @@
---!strict
---[=[
- @function copyDeep
- @within Dictionary
-
- @param dictionary T -- The dictionary to copy.
- @return T -- The copied dictionary.
-
- Copies a dictionary recursively.
-
- ```lua
- local dictionary = { hello = { world = "goodbye" } }
-
- local new = CopyDeep(dictionary) -- { hello = { world = "goodbye" } }
-
- print(new == dictionary) -- false
- print(new.hello == dictionary.hello) -- false
- ```
-]=]
-local function copyDeep(dictionary: T): T
- local new = table.clone(dictionary)
-
- for key, value in pairs(dictionary) do
- if type(value) == "table" then
- new[key] = copyDeep(value)
- end
- end
-
- return new
-end
-
-return copyDeep
diff --git a/src/Dictionary/copyDeep.luau.todo b/src/Dictionary/copyDeep.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/count.luau b/src/Dictionary/count.luau
deleted file mode 100644
index 0000ef5..0000000
--- a/src/Dictionary/count.luau
+++ /dev/null
@@ -1,42 +0,0 @@
---!strict
-local Sift = script.Parent.Parent
-
-local Util = require(Sift.Util)
-
---[=[
- @function count
- @within Dictionary
-
- @param dictionary T -- The dictionary to count.
- @param predicate? (value: T, key: K, dictionary: T) -> any -- The predicate to use to filter the dictionary.
- @return number -- The number of items in the dictionary.
-
- Counts the number of items in a dictionary.
-
- ```lua
- local dictionary = { hello = "world", goodbye = "world" }
-
- local value = Count(dictionary) -- 2
- local value = Count(dictionary, function(item, key)
- return item == "world"
- end) -- 1
- ```
-]=]
-local function count(
- dictionary: { [K]: V },
- predicate: ((value: V, key: K, dictionary: { [K]: V }) -> any)?
-): number
- local counter = 0
-
- predicate = if type(predicate) == "function" then predicate else Util.func.truthy
-
- for key, value in pairs(dictionary) do
- if predicate(value, key, dictionary) then
- counter += 1
- end
- end
-
- return counter
-end
-
-return count
diff --git a/src/Dictionary/count.luau.todo b/src/Dictionary/count.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/entries.luau b/src/Dictionary/entries.luau
deleted file mode 100644
index ca8a966..0000000
--- a/src/Dictionary/entries.luau
+++ /dev/null
@@ -1,27 +0,0 @@
---!strict
---[=[
- @function entries
- @within Dictionary
-
- @param dictionary {[K]: V} -- The dictionary to get the entries from.
- @return {{ K, V }} -- The entries in the dictionary.
-
- Returns the entries in the given dictionary as an array of key-value pairs.
-
- ```lua
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local entries = Entries(dictionary) -- { { "hello", "roblox" }, { "goodbye", "world" } }
- ```
-]=]
-local function entries(dictionary: { [K]: V }): { [number]: { [number]: K | V } }
- local result = {}
-
- for key, value in pairs(dictionary) do
- table.insert(result, { key, value })
- end
-
- return result
-end
-
-return entries
diff --git a/src/Dictionary/entries.luau.todo b/src/Dictionary/entries.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/equals.luau b/src/Dictionary/equals.luau
deleted file mode 100644
index 7d7e725..0000000
--- a/src/Dictionary/equals.luau
+++ /dev/null
@@ -1,64 +0,0 @@
---!strict
-local Sift = script.Parent.Parent
-
-local Util = require(Sift.Util)
-local _T = require(Sift.Types)
-
-local function compare(a, b)
- if type(a) ~= "table" or type(b) ~= "table" then
- return a == b
- end
-
- for key, value in pairs(a) do
- if b[key] ~= value then
- return false
- end
- end
-
- for key, value in pairs(b) do
- if a[key] ~= value then
- return false
- end
- end
-
- return true
-end
-
---[=[
- @function equals
- @within Dictionary
-
- @param ... ...{ [any]: any } -- The dictionaries to compare.
- @return boolean -- Whether the dictionaries are equal.
-
- Compares two dictionaries for equality.
-
- ```lua
- local dictionary = { hello = "world", goodbye = "world" }
- local other1 = { hello = "world", goodbye = "world" }
- local other2 = { hello = "hello", world = "goodbye" }
-
- local value = Equals(dictionary, other1) -- true
- local value = Equals(dictionary, other1, other2) -- false
- ```
-]=]
-local function equals(...: _T.AnyDictionary): boolean
- if Util.equalObjects(...) then
- return true
- end
-
- local totalArgs = select("#", ...)
- local firstItem = select(1, ...)
-
- for i = 2, totalArgs do
- local item = select(i, ...)
-
- if not compare(firstItem, item) then
- return false
- end
- end
-
- return true
-end
-
-return equals
diff --git a/src/Dictionary/equals.luau.todo b/src/Dictionary/equals.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/equalsDeep.luau b/src/Dictionary/equalsDeep.luau
deleted file mode 100644
index fba460f..0000000
--- a/src/Dictionary/equalsDeep.luau
+++ /dev/null
@@ -1,64 +0,0 @@
---!strict
-local Sift = script.Parent.Parent
-
-local Util = require(Sift.Util)
-local _T = require(Sift.Types)
-
-local function compareDeep(a, b)
- if type(a) ~= "table" or type(b) ~= "table" then
- return a == b
- end
-
- for key, value in pairs(a) do
- if not compareDeep(value, b[key]) then
- return false
- end
- end
-
- for key, value in pairs(b) do
- if not compareDeep(value, a[key]) then
- return false
- end
- end
-
- return true
-end
-
---[=[
- @function equalsDeep
- @within Dictionary
-
- @param ... ...{ [any]: any } -- The dictionaries to compare.
- @return boolean -- Whether the dictionaries are equal.
-
- Compares two dictionaries for equality using deep comparison.
-
- ```lua
- local dictionary = { hello = "world", goodbye = { world = "hello" } }
- local other1 = { hello = "world", goodbye = { world = "hello" } }
- local other2 = { hello = "hello", world = "goodbye" }
-
- local value = EqualsDeep(dictionary, other1) -- true
- local value = EqualsDeep(dictionary, other1, other2) -- false
- ```
-]=]
-local function equalsDeep(...: _T.AnyDictionary): boolean
- if Util.equalObjects(...) then
- return true
- end
-
- local totalArgs = select("#", ...)
- local firstItem = select(1, ...)
-
- for i = 2, totalArgs do
- local item = select(i, ...)
-
- if not compareDeep(firstItem, item) then
- return false
- end
- end
-
- return true
-end
-
-return equalsDeep
diff --git a/src/Dictionary/equalsDeep.luau.todo b/src/Dictionary/equalsDeep.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/every.luau b/src/Dictionary/every.luau
deleted file mode 100644
index 03337d0..0000000
--- a/src/Dictionary/every.luau
+++ /dev/null
@@ -1,37 +0,0 @@
---!strict
---[=[
- @function every
- @within Dictionary
-
- @param dictionary {[K]: V} -- The dictionary to check.
- @param predicate (value: V, key: K, dictionary: {[K]: V}) -> any -- The predicate to use to check the dictionary.
- @return boolean -- Whether every item in the dictionary passes the predicate.
-
- Checks whether every item in the dictionary passes the predicate.
-
- ```lua
- local dictionary = { hello = "world", goodbye = "world" }
-
- local value = Every(dictionary, function(value, key)
- return value == "world"
- end) -- true
-
- local value = Every(dictionary, function(value, key)
- return value == "hello"
- end) -- false
- ```
-]=]
-local function every(
- dictionary: { [K]: V },
- predicate: (value: V, key: K, dictionary: { [K]: V }) -> any
-): boolean
- for key, value in pairs(dictionary) do
- if not predicate(value, key, dictionary) then
- return false
- end
- end
-
- return true
-end
-
-return every
diff --git a/src/Dictionary/every.luau.todo b/src/Dictionary/every.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/filter.luau b/src/Dictionary/filter.luau
deleted file mode 100644
index 56f8ff3..0000000
--- a/src/Dictionary/filter.luau
+++ /dev/null
@@ -1,41 +0,0 @@
---!strict
-local Sift = script.Parent.Parent
-
-local Util = require(Sift.Util)
-
---[=[
- @function filter
- @within Dictionary
-
- @param dictionary {[K]: V} -- The dictionary to filter.
- @param predicate? (value: V, key: K, dictionary: {[K]: V}) -> any -- The predicate to use to filter the dictionary.
- @return {[K]: V} -- The filtered dictionary.
-
- Filters a dictionary using a predicate. Any items that do not pass the predicate will be removed from the dictionary.
-
- ```lua
- local dictionary = { hello = "world", goodbye = "goodbye" }
-
- local result = Filter(dictionary, function(value, key)
- return value == "world"
- end) -- { hello = "world" }
- ```
-]=]
-local function filter(
- dictionary: { [K]: V },
- predicate: ((value: V, key: K, dictionary: { [K]: V }) -> any)?
-): { [K]: V }
- local result = {}
-
- predicate = if type(predicate) == "function" then predicate else Util.func.truthy
-
- for key, value in pairs(dictionary) do
- if predicate(value, key, dictionary) then
- result[key] = value
- end
- end
-
- return result
-end
-
-return filter
diff --git a/src/Dictionary/filter.luau.todo b/src/Dictionary/filter.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/flatten.luau b/src/Dictionary/flatten.luau
deleted file mode 100644
index e4c4b00..0000000
--- a/src/Dictionary/flatten.luau
+++ /dev/null
@@ -1,52 +0,0 @@
---!strict
-local _T = require(script.Parent.Parent.Types)
-
---[=[
- @function flatten
- @within Dictionary
-
- @param dictionary T -- The dictionary to flatten.
- @param depth? number -- The depth to flatten the dictionary to.
- @return T -- The flattened dictionary.
-
- Flattens a dictionary. If depth is not specified, it will flatten the dictionary as far as it can go.
-
- ```lua
- local dictionary = {
- hello = "world",
- goodbye = {
- world = "hello",
- roblox = {
- yes = "no",
- no = "yes",
- }
- }
- }
-
- local new = Flatten(dictionary) -- { hello = "world", world = "hello", yes = "no", no = "yes" }
- local new = Flatten(dictionary, 1) -- { hello = "world", world = "hello", roblox = { yes = "no", no = "yes" } }
- ```
-]=]
-local function flatten(dictionary: _T.AnyDictionary, depth: number?): _T.AnyDictionary
- depth = if type(depth) == "number" then depth else math.huge
-
- local result = {}
-
- for key, value in pairs(dictionary :: _T.AnyDictionary) do
- if type(value) == "table" and depth > 0 then
- local nested = flatten(value, depth - 1)
-
- for resultKey, resultValue in pairs(result) do
- nested[resultKey] = resultValue
- end
-
- result = nested
- else
- result[key] = value
- end
- end
-
- return result
-end
-
-return flatten
diff --git a/src/Dictionary/flatten.luau.todo b/src/Dictionary/flatten.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/flip.luau b/src/Dictionary/flip.luau
deleted file mode 100644
index 6af59d1..0000000
--- a/src/Dictionary/flip.luau
+++ /dev/null
@@ -1,27 +0,0 @@
---!strict
---[=[
- @function flip
- @within Dictionary
-
- @param dictionary { [K]: V } -- The dictionary to flip.
- @return { [V]: K } -- The flipped dictionary.
-
- Flips a dictionary. Keys become values and values become keys.
-
- ```lua
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local new = Flip(dictionary) -- { world = "goodbye", roblox = "hello" }
- ```
-]=]
-local function flip(dictionary: { [K]: V }): { [V]: K }
- local result = {}
-
- for key, value in pairs(dictionary) do
- result[value] = key
- end
-
- return result
-end
-
-return flip
diff --git a/src/Dictionary/flip.luau.todo b/src/Dictionary/flip.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/freeze.luau b/src/Dictionary/freeze.luau
deleted file mode 100644
index 3f32a46..0000000
--- a/src/Dictionary/freeze.luau
+++ /dev/null
@@ -1,31 +0,0 @@
---!strict
-local _T = require(script.Parent.Parent.Types)
-local Copy = require(script.Parent.copy)
-
---[=[
- @function freeze
- @within Dictionary
-
- @param dictionary T -- The dictionary to freeze.
- @return T -- The frozen dictionary.
-
- Freezes the given dictionary at the top level, making it read-only.
-
- ```lua
- local dictionary = { hello = "roblox", goodbye = { world = "world" } }
-
- local new = Freeze(dictionary)
-
- new.hello = "world" -- error!
- new.goodbye.world = "hello" -- still works!
- ```
-]=]
-local function freeze(dictionary: _T.AnyDictionary): _T.AnyDictionary
- local new = Copy(dictionary)
-
- table.freeze(new)
-
- return new
-end
-
-return freeze
diff --git a/src/Dictionary/freeze.luau.todo b/src/Dictionary/freeze.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/freezeDeep.luau b/src/Dictionary/freezeDeep.luau
deleted file mode 100644
index 4356357..0000000
--- a/src/Dictionary/freezeDeep.luau
+++ /dev/null
@@ -1,38 +0,0 @@
---!strict
-local _T = require(script.Parent.Parent.Types)
-
---[=[
- @function freezeDeep
- @within Dictionary
-
- @param dictionary T -- The dictionary to freeze.
- @return T -- The frozen dictionary.
-
- Freezes the entire dictionary, making it read-only, including all nested dictionaries.
-
- ```lua
- local dictionary = { hello = "roblox", goodbye = { world = "world" } }
-
- local new = FreezeDeep(dictionary)
-
- new.hello = "world" -- error!
- new.goodbye.world = "hello" -- error!
- ```
-]=]
-local function freezeDeep(dictionary: _T.AnyDictionary): _T.AnyDictionary
- local result = {}
-
- for key, value in pairs(dictionary) do
- if type(value) == "table" then
- result[key] = freezeDeep(value)
- else
- result[key] = value
- end
- end
-
- table.freeze(result)
-
- return result
-end
-
-return freezeDeep
diff --git a/src/Dictionary/freezeDeep.luau.todo b/src/Dictionary/freezeDeep.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/fromArrays.luau b/src/Dictionary/fromArrays.luau
deleted file mode 100644
index ed6e99d..0000000
--- a/src/Dictionary/fromArrays.luau
+++ /dev/null
@@ -1,31 +0,0 @@
---!strict
---[=[
- @function fromArrays
- @within Dictionary
-
- @param keys {K} -- An array containing values to be used as keys.
- @param values {V} -- An array containing values to be used as values.
- @return {[K]: V} -- A dictionary composed of the given keys and values.
-
- Creates a dictionary from the given arrays, where the first array is used
- as keys and the second array is used as values.
-
- ```lua
- local keys = { "hello", "goodbye" }
- local values = { "roblox", "world" }
-
- local dictionary = FromArrays(keys, values) -- { hello = "roblox", goodbye = "world" }
- ```
-]=]
-local function fromArrays(keys: { K }, values: { V }): { [K]: V }
- local keysLength = #keys
- local result = {}
-
- for i = 1, keysLength do
- result[keys[i]] = values[i]
- end
-
- return result
-end
-
-return fromArrays
diff --git a/src/Dictionary/fromArrays.luau.todo b/src/Dictionary/fromArrays.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/fromEntries.luau b/src/Dictionary/fromEntries.luau
deleted file mode 100644
index 7ae818a..0000000
--- a/src/Dictionary/fromEntries.luau
+++ /dev/null
@@ -1,27 +0,0 @@
---!strict
---[=[
- @function fromEntries
- @within Dictionary
-
- @param entries {{ K, V }} -- An array of key-value pairs.
- @return {[K]: V} -- A dictionary composed of the given key-value pairs.
-
- Creates a dictionary from the given key-value pairs.
-
- ```lua
- local entries = { { "hello", "roblox" }, { "goodbye", "world" } }
-
- local dictionary = FromEntries(entries) -- { hello = "roblox", goodbye = "world" }
- ```
-]=]
-local function fromEntries(entries: { [number]: { [number]: K | V } }): { [K]: V }
- local result = {}
-
- for _, entry in ipairs(entries) do
- result[entry[1]] = entry[2]
- end
-
- return result
-end
-
-return fromEntries
diff --git a/src/Dictionary/fromEntries.luau.todo b/src/Dictionary/fromEntries.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/has.luau b/src/Dictionary/has.luau
deleted file mode 100644
index 97e9952..0000000
--- a/src/Dictionary/has.luau
+++ /dev/null
@@ -1,25 +0,0 @@
---!strict
-local _T = require(script.Parent.Parent.Types)
-
---[=[
- @function has
- @within Dictionary
-
- @param dictionary {[K]: V} -- The dictionary to check.
- @param key any -- The key to check for.
- @return boolean -- Whether or not the dictionary has the given key.
-
- Checks whether or not the given dictionary has the given key.
-
- ```lua
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local hasHello = Has(dictionary, "hello") -- true
- local hasCat = Has(dictionary, "cat") -- false
- ```
-]=]
-local function has(dictionary: _T.AnyDictionary, key: any): boolean
- return dictionary[key] ~= nil
-end
-
-return has
diff --git a/src/Dictionary/has.luau.todo b/src/Dictionary/has.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/includes.luau b/src/Dictionary/includes.luau
deleted file mode 100644
index 3106cd4..0000000
--- a/src/Dictionary/includes.luau
+++ /dev/null
@@ -1,29 +0,0 @@
---!strict
---[=[
- @function includes
- @within Dictionary
-
- @param dictionary {[K]: V} -- The dictionary to check.
- @param value V -- The value to check for.
- @return boolean -- Whether or not the dictionary includes the given value.
-
- Checks whether or not the given dictionary includes the given value.
-
- ```lua
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local includesRoblox = Includes(dictionary, "roblox") -- true
- local includesCat = Includes(dictionary, "cat") -- false
- ```
-]=]
-local function includes(dictionary: { [K]: V }, value: V): boolean
- for _, v in pairs(dictionary) do
- if v == value then
- return true
- end
- end
-
- return false
-end
-
-return includes
diff --git a/src/Dictionary/includes.luau.todo b/src/Dictionary/includes.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/init.luau b/src/Dictionary/init.luau
index f68e6eb..85ae286 100644
--- a/src/Dictionary/init.luau
+++ b/src/Dictionary/init.luau
@@ -1,51 +1,4 @@
---!strict
--[=[
- @class Dictionary
-
- Dictionaries are a type of data structure that can be used to store key-value pairs.
-
- ```lua
- local dictionary = {
- cats = 2,
- dogs = 1
- }
-
- print(dictionary.cats) -- 2
- ```
+ @class Dictionary
]=]
-local Dictionary = {
- copy = require(script.copy),
- copyDeep = require(script.copyDeep),
- count = require(script.count),
- entries = require(script.entries),
- equals = require(script.equals),
- equalsDeep = require(script.equalsDeep),
- every = require(script.every),
- filter = require(script.filter),
- flatten = require(script.flatten),
- flip = require(script.flip),
- freeze = require(script.freeze),
- freezeDeep = require(script.freezeDeep),
- fromArrays = require(script.fromArrays),
- fromEntries = require(script.fromEntries),
- has = require(script.has),
- includes = require(script.includes),
- keys = require(script.keys),
- map = require(script.map),
- merge = require(script.merge),
- mergeDeep = require(script.mergeDeep),
- removeKey = require(script.removeKey),
- removeKeys = require(script.removeKeys),
- removeValue = require(script.removeValue),
- removeValues = require(script.removeValues),
- set = require(script.set),
- some = require(script.some),
- update = require(script.update),
- values = require(script.values),
- withKeys = require(script.withKeys),
-}
-
-Dictionary.join = Dictionary.merge
-Dictionary.joinDeep = Dictionary.mergeDeep
-
-return Dictionary
+return {}
diff --git a/src/Dictionary/keys.luau b/src/Dictionary/keys.luau
deleted file mode 100644
index 40fe565..0000000
--- a/src/Dictionary/keys.luau
+++ /dev/null
@@ -1,27 +0,0 @@
---!strict
---[=[
- @function keys
- @within Dictionary
-
- @param dictionary {[K]: V} -- The dictionary to get the keys of.
- @return {K} -- An array containing the keys of the given dictionary.
-
- Gets the keys of the given dictionary as an array.
-
- ```lua
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local keys = Keys(dictionary) -- { "hello", "goodbye" }
- ```
-]=]
-local function keys(dictionary: { [K]: V }): { K }
- local result = {}
-
- for key in pairs(dictionary) do
- table.insert(result, key)
- end
-
- return result
-end
-
-return keys
diff --git a/src/Dictionary/keys.luau.todo b/src/Dictionary/keys.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/map.luau b/src/Dictionary/map.luau
deleted file mode 100644
index f878da3..0000000
--- a/src/Dictionary/map.luau
+++ /dev/null
@@ -1,40 +0,0 @@
---!strict
---[=[
- @function map
- @within Dictionary
-
- @param dictionary {[K]: V} -- The dictionary to map.
- @param mapper (value: V, key: K, dictionary: {[K]: V}) -> (Y?, X?) -- The mapper function.
- @return {[X]: Y} -- The mapped dictionary.
-
- Maps the dictionary using the mapper function. The mapper function can
- return a value and a key. If the mapper function does not return a key,
- the original key will be used.
-
- ```lua
- local dictionary = { hello = 10, goodbye = 20 }
-
- local new = Map(dictionary, function(value, key)
- return value * 2, key .. "!"
- end) -- { ["hello!"] = 20, ["goodbye!"] = 40 }
-
- local new = Map(dictionary, function(value, key)
- return value * 10
- end) -- { hello = 100, goodbye = 200 }
- ```
-]=]
-local function map(
- dictionary: { [K]: V },
- mapper: (value: V, key: K, dictionary: { [K]: V }) -> (Y?, X?)
-): { [X]: Y }
- local mapped = {}
-
- for key, value in pairs(dictionary) do
- local mappedValue, mappedKey = mapper(value, key, dictionary)
- mapped[mappedKey or key] = mappedValue
- end
-
- return mapped
-end
-
-return map
diff --git a/src/Dictionary/map.luau.todo b/src/Dictionary/map.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/merge.luau b/src/Dictionary/merge.luau
deleted file mode 100644
index f02804d..0000000
--- a/src/Dictionary/merge.luau
+++ /dev/null
@@ -1,45 +0,0 @@
---!strict
-local Sift = script.Parent.Parent
-
-local None = require(Sift.None)
-
---[=[
- @function merge
- @within Dictionary
-
- @param dictionaries? ...any -- The dictionaries to merge.
- @return T -- The merged dictionary.
-
- Merges the given dictionaries into a single dictionary. If the
- value is `None`, it will be removed from the result. The
- parameters may be any number of dictionaries or `nil`.
- Non-dictonaries will be ignored.
-
- Aliases: `join`
-
- ```lua
- local dictionary1 = { hello = "roblox", goodbye = "world" }
- local dictionary2 = { goodbye = "goodbye" }
-
- local merged = Merge(dictionary1, dictionary2) -- { hello = "roblox", goodbye = "goodbye" }
- ```
-]=]
-local function merge(...: any): T
- local result = {}
-
- for dictionaryIndex = 1, select("#", ...) do
- local dictionary = select(dictionaryIndex, ...)
-
- if type(dictionary) ~= "table" then
- continue
- end
-
- for key, value in pairs(dictionary) do
- result[key] = if value == None then nil else value
- end
- end
-
- return result
-end
-
-return merge
diff --git a/src/Dictionary/merge.luau.todo b/src/Dictionary/merge.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/mergeDeep.luau b/src/Dictionary/mergeDeep.luau
deleted file mode 100644
index e0ba505..0000000
--- a/src/Dictionary/mergeDeep.luau
+++ /dev/null
@@ -1,56 +0,0 @@
---!strict
-local Sift = script.Parent.Parent
-
-local None = require(Sift.None)
-local copyDeep = require(script.Parent.copyDeep)
-
---[=[
- @function mergeDeep
- @within Dictionary
-
- @param dictionaries? ...any -- The dictionaries to merge.
- @return T -- The merged dictionary.
-
- Merges the given dictionaries into a single dictionary. If the
- value is `None`, it will be removed from the result. This is
- recursive. The parameters may be any number of dictionaries or
- `nil`. Non-dictonaries will be ignored.
-
- Aliases: `joinDeep`
-
- ```lua
- local dictionary1 = { hello = "roblox", goodbye = { world = "goodbye" } }
- local dictionary2 = { goodbye = { world = "world" } }
-
- local merged = MergeDeep(dictionary1, dictionary2) -- { hello = "roblox", goodbye = { world = "world" } }
- ```
-]=]
-local function mergeDeep(...: any): T
- local result = {}
-
- for dictionaryIndex = 1, select("#", ...) do
- local dictionary = select(dictionaryIndex, ...)
-
- if type(dictionary) ~= "table" then
- continue
- end
-
- for key, value in pairs(dictionary) do
- if value == None then
- result[key] = nil
- elseif type(value) == "table" then
- if result[key] == nil or type(result[key]) ~= "table" then
- result[key] = copyDeep(value)
- else
- result[key] = mergeDeep(result[key], value)
- end
- else
- result[key] = value
- end
- end
- end
-
- return result
-end
-
-return mergeDeep
diff --git a/src/Dictionary/mergeDeep.luau.todo b/src/Dictionary/mergeDeep.luau.todo
new file mode 100644
index 0000000..e69de29
diff --git a/src/Dictionary/removeKey.luau b/src/Dictionary/removeKey.luau
deleted file mode 100644
index 6659fac..0000000
--- a/src/Dictionary/removeKey.luau
+++ /dev/null
@@ -1,29 +0,0 @@
---!strict
-local copy = require(script.Parent.copy)
-
---[=[
- @function removeKey
- @within Dictionary
-
- @param dictionary {[K]: V} -- The dictionary to remove the key from.
- @param key K -- The key to remove.
- @return {[K]: V} -- The dictionary without the given key.
-
- Removes the given key from the given dictionary.
-
- ```lua
- local dictionary = { hello = "roblox", goodbye = "world" }
-
- local withoutHello = RemoveKey(dictionary, "hello") -- { goodbye = "world" }
- local withoutGoodbye = RemoveKey(dictionary, "goodbye") -- { hello = "roblox" }
- ```
-]=]
-local function removeKey