0.24.x✎
Declare a function where it belongs, or onto a table.
Declare a function where it belongs, or onto a table.
Releases
- 0.24.3Room around a function declared in the flow.New2026-09-09
- 0.24.2Declare Function counts as a function everywhere.New2026-09-09
- 0.24.1Declare Function hands its function over.New2026-09-09
- 0.24.0Declare a function where it belongs, or onto a table.New2026-09-09
Warning
Worth knowing before you upgrade.
- 0.24.0On Table has to resolve to a name — a variable or a local. Luau has no syntax for attaching a function to an expression, so anything else is refused rather than half-written.
- 0.24.0The function is named where it is declared, so a Get Function above it reports that it does not exist yet rather than naming a local that has not been reached.
Added
- 0.24.0Declare Function, which declares a function where the node sits rather than at the top — the other half of Function, the way Declare Type is the other half of Declare Type at Top. Wire a table into On Table and it becomes
function TankConfig.read(tank: Model): Config; leave it unwired for a plainlocal functionat that point in the flow.
Fixed
- 0.24.3A Declare Function gets a blank line either side, the same as a hoisted one. Two run together read as a single block with an end somewhere in the middle of it.
- 0.24.2A graph with only Declare Function nodes compiles. Every Get Function was reported as pointing at a function no longer in the graph, because the check only counted the hoisted node.
- 0.24.2Declare Function can be chosen in a Get Function. The dropdown listed it, took the click and discarded it, so the selection snapped back with nothing said.
- 0.24.2Renaming one updates the references to it, and it now appears in the palette as Get <name> and in hand-written Luau completions.
- 0.24.1A Declare Function node's function can be wired into a call. Its
Functionoutput was reported as out of scope, because passing a function as a value was special-cased to the hoisted node. - 0.24.1Its header reads
Declare Function (name), with the signature underneath, instead of replacing the node's name with the function's.