Repository navigation
ToTable
Dennis Corvers edited this page Oct 23, 2026
·
1 revision
Materializes values from an iterable into a Lua array.
array = values:toTable()This method has no parameters.
A new array containing values in source iteration order.
This is a terminal operation: it enumerates the source immediately. For
dictionary-like inputs, pairs iteration order is unspecified.
local partyNames = LuaQ.from({
{ name = "Ada" },
{ name = "Bryn" },
})
:map(function(player) return player.name end)
:toTable()
-- { "Ada", "Bryn" }- Home
- Getting Started
-
Functions
- aggregate
- all
- any
- concat
- contains
- count
- create
- createFrom
- deepCopy
- difference
- elementAt
- elementAtOrDefault
- first
- firstOrDefault
- flatMap
- foreach
- groupBy
- groupByResult
- indexOf
- intersect
- ipairs
- last
- lastOrDefault
- map
- max
- min
- pairs
- sequenceEquals
- single
- singleOrDefault
- sort
- sortBy
- sortByDescending
- sortDescending
- sum
- take
- takeWhile
- thenBy
- thenByDecending
- toLookup
- toMap
- toSet
- toTable
- union
- unique
- where
- zip
- Aliases