Sha256: f4a7ff687aaf6223ad0e549030d11834103469e40898de922fd0a60cef12ad21

Contents?: true

Size: 1.36 KB

Versions: 51

Compression:

Stored size: 1.36 KB

Contents

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.Settings = exports.walkStream = exports.walkSync = exports.walk = void 0;
const async_1 = require("./providers/async");
const stream_1 = require("./providers/stream");
const sync_1 = require("./providers/sync");
const settings_1 = require("./settings");
exports.Settings = settings_1.default;
function walk(directory, optionsOrSettingsOrCallback, callback) {
    if (typeof optionsOrSettingsOrCallback === 'function') {
        new async_1.default(directory, getSettings()).read(optionsOrSettingsOrCallback);
        return;
    }
    new async_1.default(directory, getSettings(optionsOrSettingsOrCallback)).read(callback);
}
exports.walk = walk;
function walkSync(directory, optionsOrSettings) {
    const settings = getSettings(optionsOrSettings);
    const provider = new sync_1.default(directory, settings);
    return provider.read();
}
exports.walkSync = walkSync;
function walkStream(directory, optionsOrSettings) {
    const settings = getSettings(optionsOrSettings);
    const provider = new stream_1.default(directory, settings);
    return provider.read();
}
exports.walkStream = walkStream;
function getSettings(settingsOrOptions = {}) {
    if (settingsOrOptions instanceof settings_1.default) {
        return settingsOrOptions;
    }
    return new settings_1.default(settingsOrOptions);
}

Version data entries

51 entries across 51 versions & 3 rubygems

Version Path
immosquare-cleaner-0.1.41 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.40 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.39 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.38 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.32 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.31 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.30 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.29 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.28 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.27 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.26 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.25 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.24 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.23 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.22 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.21 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.20 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.19 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.18 node_modules/@nodelib/fs.walk/out/index.js
immosquare-cleaner-0.1.17 node_modules/@nodelib/fs.walk/out/index.js