Buckets:

imerfanrajabee's picture
download
raw
626 Bytes
import { ArgumentOutOfRangeError } from '../util/ArgumentOutOfRangeError';
import { filter } from './filter';
import { throwIfEmpty } from './throwIfEmpty';
import { defaultIfEmpty } from './defaultIfEmpty';
import { take } from './take';
export function elementAt(index, defaultValue) {
if (index < 0) {
throw new ArgumentOutOfRangeError();
}
const hasDefaultValue = arguments.length >= 2;
return (source) => source.pipe(filter((v, i) => i === index), take(1), hasDefaultValue ? defaultIfEmpty(defaultValue) : throwIfEmpty(() => new ArgumentOutOfRangeError()));
}
//# sourceMappingURL=elementAt.js.map

Xet Storage Details

Size:
626 Bytes
·
Xet hash:
8ba86f1f933dd895f7f2c4f56c41d9ead30250d4e6c3499bd9558dea4d2aa32d

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.