-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhawaii.d.luau
37 lines (31 loc) · 924 Bytes
/
hawaii.d.luau
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
type HWIObject = {
compressed: boolean,
hash: string?,
filePath: string?,
content: buffer,
Open: (HWIObject) -> buffer
}
type HWIPackage = {
objects: {[string]: HWIObject},
}
--[=[
Imports a module with a given set of imports, or `*` for the entire `exports`
table.
Supports one of two path types
* `source` - uses an alias path defined in `hawaii.toml`
* `/sources/source` - imports a file from the top of the package
* Relative paths are not supported yet
]=]--
declare import: (
(string, ...string) -> {from: (string) -> any}
)
--[=[
A table for writing the module exports, should be returned from all modules.
This table is frozen once returned and cant be written to further.
]=]--
declare exports: {[string]: any}
--[[
A static proxy reference to this HWI package. Only exports a frozen copy of
the objects table, and hashes if enabled within the root package.
]]--
declare package: HWIPackage