refactor!: create monorepo

This commit is contained in:
Richard 2024-10-12 16:08:36 -07:00
parent b038bf1f70
commit 0416717f6c
68 changed files with 488 additions and 416 deletions

View file

@ -0,0 +1,32 @@
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local Charm = require(ReplicatedStorage.DevPackages.Charm)
local computed = Charm.computed
local atom = Charm.atom
local function parameterGenerator()
return atom(0)
end
local benchmarks = {
atom = function(_, state: any)
for _ = 1, 500 do
state(math.random(1, 2))
end
end,
computed = function(_, state: any)
computed(function()
return 2 * state()
end)
for _ = 1, 500 do
state(math.random(1, 2))
end
end,
}
return {
ParameterGenerator = parameterGenerator,
Functions = benchmarks,
}