Skip to content

Using standard iterators #1

@Yomguithereal

Description

@Yomguithereal

Hello @acarl005. Thanks for the awesome library. Would you consider switching from generators (using the yield keyword) to basic JS iterators (just the object with the next function & following JS iterator protocol) so that it remains possible to use your library with more old-school JS engines (+ attaching Symbol.iterator so that your API remains totally unchanged)?

I could help you achieve that by recoding the necessary parts if you'd like.

As a side note, I am wondering whether you attempted to benchmark generators vs. iterator protocol and if you went for generators for obvious performance reasons I missed.

Have a good day.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions