Module:Util/tables/_property
< Module:Util | tables
A curried version of Module:Util/tables/property.
_property(key)
Returns
- A function that accepts a table and returns the table's value for
key
Examples
# | Input | Output | Status |
---|---|---|---|
1 | local getAbbr = util.tables._property("abbr")
return getAbbr({ abbr = "OoT", title = "Ocarina of Time" })
| "OoT"
| |
2 | local getAbbr = util.tables._property("abbr")
return getAbbr({ title = "Bayonetta" })
| nil
|