revert: build: remove project json files (#46)

This commit is contained in:
littensy 2025-03-09 18:03:54 -07:00
parent 990d71cd5b
commit d7a1f62c3c
49 changed files with 97 additions and 92 deletions

View file

@ -0,0 +1,6 @@
{
"name": "Charm",
"tree": {
"$path": "src"
}
}

View file

@ -1,7 +0,0 @@
local src = require(script.src)
export type Atom<State> = src.Atom<State>
export type Selector<State> = src.Selector<State>
export type Molecule<State> = src.Selector<State>
return src

View file

@ -4,8 +4,8 @@
"description": "An atomic state management library for Roblox",
"repository": "littensy/charm",
"license": "MIT",
"main": "init.luau",
"types": "index.d.ts",
"main": "src/init.luau",
"types": "src/index.d.ts",
"scripts": {
"prepare": "cp ../../LICENSE.md . && cp ../../README.md .",
"publish:wally": "wally publish"

View file

@ -10,6 +10,7 @@ local types = require(script.types)
export type Atom<State> = types.Atom<State>
export type Selector<State> = types.Selector<State>
export type Molecule<State> = types.Selector<State>
export type SyncPayload = types.SyncPayload
return {
atom = atom,

View file

@ -31,4 +31,13 @@ export type AtomOptions<T> = {
equals: (prev: T, next: T) -> boolean,
}
--[=[
A payload that can be sent from the server to the client to synchronize
state between the two.
]=]
export type SyncPayload = {
type: "patch" | "init",
data: { [any]: any },
}
return nil

View file

@ -3,7 +3,5 @@ name = "littensy/charm"
version = "0.10.0"
registry = "https://github.com/UpliftGames/wally-index"
realm = "shared"
exclude = ["package.json", "node_modules"]
include = ["LICENSE.md"]
[dependencies]