[
https://issues.apache.org/jira/browse/ARROW-9982?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17202664#comment-17202664
]
Paul Taylor edited comment on ARROW-9982 at 9/26/20, 7:44 PM:
--------------------------------------------------------------
{code:javascript}¯\_(ツ)_/¯{code}
We're getting complaints about how large and un-tree-shakeable the library is
already. I don't see a reason to add more unrelated functionality, especially
when it already exists in other tree-shakeable libraries like Ix.
Otherwise, you can do `for...of` over any iterable type already, or have your
own map implementation (no need to use Ix for something so simple)
{code:javascript}
function* map(source, project) { for (let x of source) yield project(x); }
for (let value of map(vector, (x) => x + 1)) {
console.log(value);
}
{code}
was (Author: paul.e.taylor):
¯\_(ツ)_/¯
We're getting complaints about how large and un-tree-shakeable the library is
already. I don't see a reason to add more unrelated functionality, especially
when it already exists in other tree-shakeable libraries like Ix.
Otherwise, you can do `for...of` over any iterable type already, or have your
own map implementation (no need to use Ix for something so simple)
{code:javascript}
function* map(source, project) { for (let x of source) yield project(x); }
for (let value of map(vector, (x) => x + 1)) {
console.log(value);
}
{code}
> [JS] IterableArrayLike should support map
> -----------------------------------------
>
> Key: ARROW-9982
> URL: https://issues.apache.org/jira/browse/ARROW-9982
> Project: Apache Arrow
> Issue Type: Improvement
> Components: JavaScript
> Reporter: Dominik Moritz
> Priority: Minor
>
> `table.toArray()` returns an `IterableArrayLike` and I would like to be able
> to `map` a function to it.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)