Skip to content

Add Array.pluck function - #37

Merged
jeparlefrancais merged 2 commits into
mainfrom
array-pluck
Mar 19, 2026
Merged

jeparlefrancais merged 2 commits into
mainfrom
array-pluck

Conversation

@jeparlefrancais

Copy link
Copy Markdown
Contributor

Closes #16

Add Array.pluck to map an array to one of its field.

local rows = {
    { id = 1, name = 'Ada' },
    { id = 2, name = 'Grace' },
}
local names = Array.pluck(rows, 'name')
-- names is { 'Ada', 'Grace' }

  • add entry to the changelog
  • update relevant documentation

@jeparlefrancais
jeparlefrancais merged commit 06ae5df into main Mar 19, 2026
1 check passed
@jeparlefrancais
jeparlefrancais deleted the array-pluck branch March 19, 2026 22:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Array.pluck

1 participant