Skip to content

3.1.1

Compare
Choose a tag to compare
@mrmlnc mrmlnc released this 01 Dec 10:35
· 262 commits to master since this release

🐛 Bug fixes

Stream is not closed when the receiver is closed (#239)

Previously, we read directories in the stream, even after the receiver is closed. Now we stop reading after closing the receiver by .emit('end'), .destroy() or for await...of.

const fg = require('fast-glob');

(async () => {
    const stream = fg.stream('**');

    for await (const entry of stream) {
        console.log(entry);

        return;
    }
})();

Most likely, in future releases, we will improve integration with streams (#243).