@bleedingdev/modern-js-utils 3.9.0-ultramodern.2 → 3.9.0-ultramodern.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/cli/require.js +10 -1
- package/dist/compiled/chokidar/types/index.d.ts +1 -1
- package/dist/compiled/fast-glob/@nodelib/fs.scandir/out/adapters/fs.d.ts +1 -1
- package/dist/compiled/fast-glob/@nodelib/fs.scandir/out/settings.d.ts +1 -1
- package/dist/compiled/fast-glob/@nodelib/fs.walk/out/index.d.ts +1 -1
- package/dist/compiled/fast-glob/@nodelib/fs.walk/out/readers/async.d.ts +1 -1
- package/dist/compiled/fast-glob/@nodelib/fs.walk/out/settings.d.ts +1 -1
- package/dist/compiled/fast-glob/@nodelib/fs.walk/out/types/index.d.ts +1 -1
- package/dist/compiled/fast-glob/out/types/index.d.ts +1 -1
- package/dist/compiled/inquirer/lib/prompts/base.d.ts +100 -0
- package/dist/compiled/inquirer/lib/prompts/checkbox.d.ts +116 -0
- package/dist/compiled/inquirer/lib/prompts/confirm.d.ts +53 -0
- package/dist/compiled/inquirer/lib/prompts/editor.d.ts +101 -0
- package/dist/compiled/inquirer/lib/prompts/expand.d.ts +149 -0
- package/dist/compiled/inquirer/lib/prompts/input.d.ts +82 -0
- package/dist/compiled/inquirer/lib/prompts/list.d.ts +89 -0
- package/dist/compiled/inquirer/lib/prompts/number.d.ts +32 -0
- package/dist/compiled/inquirer/lib/prompts/password.d.ts +82 -0
- package/dist/compiled/inquirer/lib/prompts/rawlist.d.ts +111 -0
- package/dist/compiled/inquirer/lib/utils/events.d.ts +72 -0
- package/dist/compiled/inquirer/lib/utils/incrementListIndex.d.ts +23 -0
- package/dist/compiled/inquirer/lib/utils/paginator.d.ts +55 -0
- package/dist/compiled/inquirer/lib/utils/readline.d.ts +56 -0
- package/dist/compiled/inquirer/lib/utils/screen-manager.d.ts +90 -0
- package/dist/compiled/inquirer/lib/utils/utils.d.ts +30 -0
- package/dist/compiled/inquirer/rxjs/LICENSE.txt +202 -0
- package/dist/compiled/inquirer/rxjs/ajax/index.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/fetch/index.d.ts +2 -0
- package/dist/compiled/inquirer/rxjs/index.d.ts +173 -0
- package/dist/compiled/inquirer/rxjs/internal/AnyCatcher.d.ts +10 -0
- package/dist/compiled/inquirer/rxjs/internal/AsyncSubject.d.ts +13 -0
- package/dist/compiled/inquirer/rxjs/internal/BehaviorSubject.d.ts +13 -0
- package/dist/compiled/inquirer/rxjs/internal/Notification.d.ts +175 -0
- package/dist/compiled/inquirer/rxjs/internal/NotificationFactories.d.ts +2 -0
- package/dist/compiled/inquirer/rxjs/internal/Observable.d.ts +121 -0
- package/dist/compiled/inquirer/rxjs/internal/Operator.d.ts +9 -0
- package/dist/compiled/inquirer/rxjs/internal/ReplaySubject.d.ts +49 -0
- package/dist/compiled/inquirer/rxjs/internal/Scheduler.d.ts +53 -0
- package/dist/compiled/inquirer/rxjs/internal/Subject.d.ts +54 -0
- package/dist/compiled/inquirer/rxjs/internal/Subscriber.d.ts +72 -0
- package/dist/compiled/inquirer/rxjs/internal/Subscription.d.ts +92 -0
- package/dist/compiled/inquirer/rxjs/internal/ajax/AjaxResponse.d.ts +115 -0
- package/dist/compiled/inquirer/rxjs/internal/ajax/ajax.d.ts +227 -0
- package/dist/compiled/inquirer/rxjs/internal/ajax/errors.d.ts +65 -0
- package/dist/compiled/inquirer/rxjs/internal/ajax/getXHRResponse.d.ts +14 -0
- package/dist/compiled/inquirer/rxjs/internal/ajax/types.d.ts +200 -0
- package/dist/compiled/inquirer/rxjs/internal/config.d.ts +73 -0
- package/dist/compiled/inquirer/rxjs/internal/firstValueFrom.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/lastValueFrom.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/ConnectableObservable.d.ts +42 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/bindCallback.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/bindCallbackInternals.d.ts +4 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/bindNodeCallback.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/combineLatest.d.ts +33 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/concat.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/connectable.d.ts +27 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/defer.d.ts +51 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/dom/WebSocketSubject.d.ts +173 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/dom/animationFrames.d.ts +76 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/dom/fetch.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/dom/webSocket.d.ts +159 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/empty.d.ts +72 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/forkJoin.d.ts +24 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/from.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/fromEvent.d.ts +45 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/fromEventPattern.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/fromSubscribable.d.ts +14 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/generate.d.ts +314 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/iif.d.ts +82 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/innerFrom.d.ts +21 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/interval.d.ts +48 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/merge.d.ts +9 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/never.d.ts +40 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/of.d.ts +14 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/onErrorResumeNext.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/pairs.d.ts +19 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/partition.d.ts +9 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/race.d.ts +12 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/range.d.ts +8 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/throwError.d.ts +115 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/timer.d.ts +126 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/using.d.ts +30 -0
- package/dist/compiled/inquirer/rxjs/internal/observable/zip.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/OperatorSubscriber.d.ts +41 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/audit.d.ts +48 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/auditTime.d.ts +50 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/buffer.d.ts +41 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/bufferCount.d.ts +54 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/bufferTime.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/bufferToggle.d.ts +46 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/bufferWhen.d.ts +41 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/catchError.d.ts +4 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/combineAll.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/combineLatest.d.ts +10 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/combineLatestAll.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/combineLatestWith.d.ts +43 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/concat.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/concatAll.d.ts +59 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/concatMap.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/concatMapTo.d.ts +8 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/concatWith.d.ts +43 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/connect.d.ts +87 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/count.d.ts +58 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/debounce.d.ts +61 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/debounceTime.d.ts +59 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/defaultIfEmpty.d.ts +38 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/delay.d.ts +59 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/delayWhen.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/dematerialize.d.ts +51 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/distinct.d.ts +60 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/distinctUntilChanged.d.ts +4 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/distinctUntilKeyChanged.d.ts +4 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/elementAt.d.ts +51 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/endWith.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/every.d.ts +9 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/exhaust.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/exhaustAll.d.ts +47 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/exhaustMap.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/expand.d.ts +9 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/filter.d.ts +9 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/finalize.d.ts +64 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/find.d.ts +12 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/findIndex.d.ts +9 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/first.d.ts +9 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/flatMap.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/groupBy.d.ts +119 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/ignoreElements.d.ts +38 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/isEmpty.d.ts +64 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/joinAllInternals.d.ts +14 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/last.d.ts +8 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/map.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/mapTo.d.ts +10 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/materialize.d.ts +52 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/max.d.ts +50 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/merge.d.ts +10 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/mergeAll.d.ts +62 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/mergeInternals.d.ts +18 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/mergeMap.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/mergeMapTo.d.ts +9 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/mergeScan.d.ts +68 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/mergeWith.d.ts +44 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/min.d.ts +50 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/multicast.d.ts +63 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/observeOn.d.ts +56 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/onErrorResumeNextWith.d.ts +8 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/pairwise.d.ts +46 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/partition.d.ts +54 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/pluck.d.ts +18 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/publish.d.ts +30 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/publishBehavior.d.ts +19 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/publishLast.d.ts +69 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/publishReplay.d.ts +56 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/race.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/raceWith.d.ts +29 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/reduce.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/refCount.d.ts +61 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/repeat.d.ts +108 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/repeatWhen.d.ts +38 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/retry.d.ts +28 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/retryWhen.d.ts +61 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/sample.d.ts +43 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/sampleTime.d.ts +46 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/scan.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/scanInternals.d.ts +12 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/sequenceEqual.d.ts +60 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/share.d.ts +43 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/shareReplay.d.ts +10 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/single.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/skip.d.ts +36 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/skipLast.d.ts +45 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/skipUntil.d.ts +48 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/skipWhile.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/startWith.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/subscribeOn.d.ts +62 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/switchAll.d.ts +61 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/switchMap.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/switchMapTo.d.ts +8 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/switchScan.d.ts +20 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/take.d.ts +45 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/takeLast.d.ts +42 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/takeUntil.d.ts +41 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/takeWhile.d.ts +8 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/tap.d.ts +72 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/throttle.d.ts +78 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/throttleTime.d.ts +53 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/throwIfEmpty.d.ts +39 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/timeInterval.d.ts +50 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/timeout.d.ts +255 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/timeoutWith.d.ts +8 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/timestamp.d.ts +35 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/toArray.d.ts +33 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/window.d.ts +48 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/windowCount.d.ts +65 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/windowTime.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/windowToggle.d.ts +49 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/windowWhen.d.ts +49 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/withLatestFrom.d.ts +4 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/zip.d.ts +10 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/zipAll.d.ts +14 -0
- package/dist/compiled/inquirer/rxjs/internal/operators/zipWith.d.ts +26 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduled/scheduleArray.d.ts +4 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduled/scheduleAsyncIterable.d.ts +4 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduled/scheduleIterable.d.ts +9 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduled/scheduleObservable.d.ts +3 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduled/schedulePromise.d.ts +3 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduled/scheduleReadableStreamLike.d.ts +4 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduled/scheduled.d.ts +15 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/Action.d.ts +30 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/AnimationFrameAction.d.ts +12 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/AnimationFrameScheduler.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/AsapAction.d.ts +12 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/AsapScheduler.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/AsyncAction.d.ts +24 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/AsyncScheduler.d.ts +9 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/QueueAction.d.ts +14 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/QueueScheduler.d.ts +4 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/VirtualTimeScheduler.d.ts +48 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/animationFrame.d.ts +38 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/animationFrameProvider.d.ts +13 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/asap.d.ts +41 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/async.d.ts +53 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/dateTimestampProvider.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/immediateProvider.d.ts +14 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/intervalProvider.d.ts +14 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/performanceTimestampProvider.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/queue.d.ts +69 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/timeoutProvider.d.ts +14 -0
- package/dist/compiled/inquirer/rxjs/internal/scheduler/timerHandle.d.ts +2 -0
- package/dist/compiled/inquirer/rxjs/internal/symbol/iterator.d.ts +3 -0
- package/dist/compiled/inquirer/rxjs/internal/symbol/observable.d.ts +8 -0
- package/dist/compiled/inquirer/rxjs/internal/testing/ColdObservable.d.ts +16 -0
- package/dist/compiled/inquirer/rxjs/internal/testing/HotObservable.d.ts +15 -0
- package/dist/compiled/inquirer/rxjs/internal/testing/SubscriptionLog.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/testing/SubscriptionLoggable.d.ts +9 -0
- package/dist/compiled/inquirer/rxjs/internal/testing/TestMessage.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/testing/TestScheduler.d.ts +88 -0
- package/dist/compiled/inquirer/rxjs/internal/types.d.ts +307 -0
- package/dist/compiled/inquirer/rxjs/internal/util/ArgumentOutOfRangeError.d.ts +19 -0
- package/dist/compiled/inquirer/rxjs/internal/util/EmptyError.d.ts +21 -0
- package/dist/compiled/inquirer/rxjs/internal/util/Immediate.d.ts +14 -0
- package/dist/compiled/inquirer/rxjs/internal/util/NotFoundError.d.ts +17 -0
- package/dist/compiled/inquirer/rxjs/internal/util/ObjectUnsubscribedError.d.ts +20 -0
- package/dist/compiled/inquirer/rxjs/internal/util/SequenceError.d.ts +17 -0
- package/dist/compiled/inquirer/rxjs/internal/util/UnsubscriptionError.d.ts +16 -0
- package/dist/compiled/inquirer/rxjs/internal/util/applyMixins.d.ts +2 -0
- package/dist/compiled/inquirer/rxjs/internal/util/args.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/internal/util/argsArgArrayOrObject.d.ts +11 -0
- package/dist/compiled/inquirer/rxjs/internal/util/argsOrArgArray.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/util/arrRemove.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/util/createErrorClass.d.ts +11 -0
- package/dist/compiled/inquirer/rxjs/internal/util/createObject.d.ts +2 -0
- package/dist/compiled/inquirer/rxjs/internal/util/errorContext.d.ts +14 -0
- package/dist/compiled/inquirer/rxjs/internal/util/executeSchedule.d.ts +5 -0
- package/dist/compiled/inquirer/rxjs/internal/util/identity.d.ts +44 -0
- package/dist/compiled/inquirer/rxjs/internal/util/isArrayLike.d.ts +2 -0
- package/dist/compiled/inquirer/rxjs/internal/util/isAsyncIterable.d.ts +2 -0
- package/dist/compiled/inquirer/rxjs/internal/util/isDate.d.ts +9 -0
- package/dist/compiled/inquirer/rxjs/internal/util/isFunction.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/util/isInteropObservable.d.ts +4 -0
- package/dist/compiled/inquirer/rxjs/internal/util/isIterable.d.ts +3 -0
- package/dist/compiled/inquirer/rxjs/internal/util/isObservable.d.ts +8 -0
- package/dist/compiled/inquirer/rxjs/internal/util/isPromise.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/util/isReadableStreamLike.d.ts +4 -0
- package/dist/compiled/inquirer/rxjs/internal/util/isScheduler.d.ts +3 -0
- package/dist/compiled/inquirer/rxjs/internal/util/lift.d.ts +15 -0
- package/dist/compiled/inquirer/rxjs/internal/util/mapOneOrManyArgs.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/util/noop.d.ts +2 -0
- package/dist/compiled/inquirer/rxjs/internal/util/not.d.ts +2 -0
- package/dist/compiled/inquirer/rxjs/internal/util/pipe.d.ts +14 -0
- package/dist/compiled/inquirer/rxjs/internal/util/reportUnhandledError.d.ts +11 -0
- package/dist/compiled/inquirer/rxjs/internal/util/subscribeToArray.d.ts +7 -0
- package/dist/compiled/inquirer/rxjs/internal/util/throwUnobservableError.d.ts +6 -0
- package/dist/compiled/inquirer/rxjs/internal/util/workarounds.d.ts +2 -0
- package/dist/compiled/inquirer/rxjs/operators/index.d.ts +114 -0
- package/dist/compiled/inquirer/rxjs/testing/index.d.ts +2 -0
- package/dist/compiled/inquirer/rxjs/webSocket/index.d.ts +3 -0
- package/dist/compiled/inquirer/types-license +21 -0
- package/dist/compiled/lodash/index.d.ts +1 -11
- package/dist/compiled/upath/upath.d.ts +2 -2
- package/dist/esm/cli/require.mjs +10 -1
- package/dist/esm-node/cli/require.mjs +10 -1
- package/package.json +4 -3
- package/rslib.config.mts +2 -0
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
import { Operator } from './Operator';
|
|
2
|
+
import { Subscriber } from './Subscriber';
|
|
3
|
+
import { Subscription } from './Subscription';
|
|
4
|
+
import { TeardownLogic, OperatorFunction, Subscribable, Observer } from './types';
|
|
5
|
+
/**
|
|
6
|
+
* A representation of any set of values over any amount of time. This is the most basic building block
|
|
7
|
+
* of RxJS.
|
|
8
|
+
*/
|
|
9
|
+
export declare class Observable<T> implements Subscribable<T> {
|
|
10
|
+
/**
|
|
11
|
+
* @deprecated Internal implementation detail, do not use directly. Will be made internal in v8.
|
|
12
|
+
*/
|
|
13
|
+
source: Observable<any> | undefined;
|
|
14
|
+
/**
|
|
15
|
+
* @deprecated Internal implementation detail, do not use directly. Will be made internal in v8.
|
|
16
|
+
*/
|
|
17
|
+
operator: Operator<any, T> | undefined;
|
|
18
|
+
/**
|
|
19
|
+
* @param subscribe The function that is called when the Observable is
|
|
20
|
+
* initially subscribed to. This function is given a Subscriber, to which new values
|
|
21
|
+
* can be `next`ed, or an `error` method can be called to raise an error, or
|
|
22
|
+
* `complete` can be called to notify of a successful completion.
|
|
23
|
+
*/
|
|
24
|
+
constructor(subscribe?: (this: Observable<T>, subscriber: Subscriber<T>) => TeardownLogic);
|
|
25
|
+
/**
|
|
26
|
+
* Creates a new Observable by calling the Observable constructor
|
|
27
|
+
* @param subscribe the subscriber function to be passed to the Observable constructor
|
|
28
|
+
* @return A new observable.
|
|
29
|
+
* @deprecated Use `new Observable()` instead. Will be removed in v8.
|
|
30
|
+
*/
|
|
31
|
+
static create: (...args: any[]) => any;
|
|
32
|
+
/**
|
|
33
|
+
* Creates a new Observable, with this Observable instance as the source, and the passed
|
|
34
|
+
* operator defined as the new observable's operator.
|
|
35
|
+
* @param operator the operator defining the operation to take on the observable
|
|
36
|
+
* @return A new observable with the Operator applied.
|
|
37
|
+
* @deprecated Internal implementation detail, do not use directly. Will be made internal in v8.
|
|
38
|
+
* If you have implemented an operator using `lift`, it is recommended that you create an
|
|
39
|
+
* operator by simply returning `new Observable()` directly. See "Creating new operators from
|
|
40
|
+
* scratch" section here: https://rxjs.dev/guide/operators
|
|
41
|
+
*/
|
|
42
|
+
lift<R>(operator?: Operator<T, R>): Observable<R>;
|
|
43
|
+
subscribe(observerOrNext?: Partial<Observer<T>> | ((value: T) => void)): Subscription;
|
|
44
|
+
/** @deprecated Instead of passing separate callback arguments, use an observer argument. Signatures taking separate callback arguments will be removed in v8. Details: https://rxjs.dev/deprecations/subscribe-arguments */
|
|
45
|
+
subscribe(next?: ((value: T) => void) | null, error?: ((error: any) => void) | null, complete?: (() => void) | null): Subscription;
|
|
46
|
+
/**
|
|
47
|
+
* Used as a NON-CANCELLABLE means of subscribing to an observable, for use with
|
|
48
|
+
* APIs that expect promises, like `async/await`. You cannot unsubscribe from this.
|
|
49
|
+
*
|
|
50
|
+
* **WARNING**: Only use this with observables you *know* will complete. If the source
|
|
51
|
+
* observable does not complete, you will end up with a promise that is hung up, and
|
|
52
|
+
* potentially all of the state of an async function hanging out in memory. To avoid
|
|
53
|
+
* this situation, look into adding something like {@link timeout}, {@link take},
|
|
54
|
+
* {@link takeWhile}, or {@link takeUntil} amongst others.
|
|
55
|
+
*
|
|
56
|
+
* #### Example
|
|
57
|
+
*
|
|
58
|
+
* ```ts
|
|
59
|
+
* import { interval, take } from '..';
|
|
60
|
+
*
|
|
61
|
+
* const source$ = interval(1000).pipe(take(4));
|
|
62
|
+
*
|
|
63
|
+
* async function getTotal() {
|
|
64
|
+
* let total = 0;
|
|
65
|
+
*
|
|
66
|
+
* await source$.forEach(value => {
|
|
67
|
+
* total += value;
|
|
68
|
+
* console.log('observable -> ' + value);
|
|
69
|
+
* });
|
|
70
|
+
*
|
|
71
|
+
* return total;
|
|
72
|
+
* }
|
|
73
|
+
*
|
|
74
|
+
* getTotal().then(
|
|
75
|
+
* total => console.log('Total: ' + total)
|
|
76
|
+
* );
|
|
77
|
+
*
|
|
78
|
+
* // Expected:
|
|
79
|
+
* // 'observable -> 0'
|
|
80
|
+
* // 'observable -> 1'
|
|
81
|
+
* // 'observable -> 2'
|
|
82
|
+
* // 'observable -> 3'
|
|
83
|
+
* // 'Total: 6'
|
|
84
|
+
* ```
|
|
85
|
+
*
|
|
86
|
+
* @param next A handler for each value emitted by the observable.
|
|
87
|
+
* @return A promise that either resolves on observable completion or
|
|
88
|
+
* rejects with the handled error.
|
|
89
|
+
*/
|
|
90
|
+
forEach(next: (value: T) => void): Promise<void>;
|
|
91
|
+
/**
|
|
92
|
+
* @param next a handler for each value emitted by the observable
|
|
93
|
+
* @param promiseCtor a constructor function used to instantiate the Promise
|
|
94
|
+
* @return a promise that either resolves on observable completion or
|
|
95
|
+
* rejects with the handled error
|
|
96
|
+
* @deprecated Passing a Promise constructor will no longer be available
|
|
97
|
+
* in upcoming versions of RxJS. This is because it adds weight to the library, for very
|
|
98
|
+
* little benefit. If you need this functionality, it is recommended that you either
|
|
99
|
+
* polyfill Promise, or you create an adapter to convert the returned native promise
|
|
100
|
+
* to whatever promise implementation you wanted. Will be removed in v8.
|
|
101
|
+
*/
|
|
102
|
+
forEach(next: (value: T) => void, promiseCtor: PromiseConstructorLike): Promise<void>;
|
|
103
|
+
pipe(): Observable<T>;
|
|
104
|
+
pipe<A>(op1: OperatorFunction<T, A>): Observable<A>;
|
|
105
|
+
pipe<A, B>(op1: OperatorFunction<T, A>, op2: OperatorFunction<A, B>): Observable<B>;
|
|
106
|
+
pipe<A, B, C>(op1: OperatorFunction<T, A>, op2: OperatorFunction<A, B>, op3: OperatorFunction<B, C>): Observable<C>;
|
|
107
|
+
pipe<A, B, C, D>(op1: OperatorFunction<T, A>, op2: OperatorFunction<A, B>, op3: OperatorFunction<B, C>, op4: OperatorFunction<C, D>): Observable<D>;
|
|
108
|
+
pipe<A, B, C, D, E>(op1: OperatorFunction<T, A>, op2: OperatorFunction<A, B>, op3: OperatorFunction<B, C>, op4: OperatorFunction<C, D>, op5: OperatorFunction<D, E>): Observable<E>;
|
|
109
|
+
pipe<A, B, C, D, E, F>(op1: OperatorFunction<T, A>, op2: OperatorFunction<A, B>, op3: OperatorFunction<B, C>, op4: OperatorFunction<C, D>, op5: OperatorFunction<D, E>, op6: OperatorFunction<E, F>): Observable<F>;
|
|
110
|
+
pipe<A, B, C, D, E, F, G>(op1: OperatorFunction<T, A>, op2: OperatorFunction<A, B>, op3: OperatorFunction<B, C>, op4: OperatorFunction<C, D>, op5: OperatorFunction<D, E>, op6: OperatorFunction<E, F>, op7: OperatorFunction<F, G>): Observable<G>;
|
|
111
|
+
pipe<A, B, C, D, E, F, G, H>(op1: OperatorFunction<T, A>, op2: OperatorFunction<A, B>, op3: OperatorFunction<B, C>, op4: OperatorFunction<C, D>, op5: OperatorFunction<D, E>, op6: OperatorFunction<E, F>, op7: OperatorFunction<F, G>, op8: OperatorFunction<G, H>): Observable<H>;
|
|
112
|
+
pipe<A, B, C, D, E, F, G, H, I>(op1: OperatorFunction<T, A>, op2: OperatorFunction<A, B>, op3: OperatorFunction<B, C>, op4: OperatorFunction<C, D>, op5: OperatorFunction<D, E>, op6: OperatorFunction<E, F>, op7: OperatorFunction<F, G>, op8: OperatorFunction<G, H>, op9: OperatorFunction<H, I>): Observable<I>;
|
|
113
|
+
pipe<A, B, C, D, E, F, G, H, I>(op1: OperatorFunction<T, A>, op2: OperatorFunction<A, B>, op3: OperatorFunction<B, C>, op4: OperatorFunction<C, D>, op5: OperatorFunction<D, E>, op6: OperatorFunction<E, F>, op7: OperatorFunction<F, G>, op8: OperatorFunction<G, H>, op9: OperatorFunction<H, I>, ...operations: OperatorFunction<any, any>[]): Observable<unknown>;
|
|
114
|
+
/** @deprecated Replaced with {@link firstValueFrom} and {@link lastValueFrom}. Will be removed in v8. Details: https://rxjs.dev/deprecations/to-promise */
|
|
115
|
+
toPromise(): Promise<T | undefined>;
|
|
116
|
+
/** @deprecated Replaced with {@link firstValueFrom} and {@link lastValueFrom}. Will be removed in v8. Details: https://rxjs.dev/deprecations/to-promise */
|
|
117
|
+
toPromise(PromiseCtor: typeof Promise): Promise<T | undefined>;
|
|
118
|
+
/** @deprecated Replaced with {@link firstValueFrom} and {@link lastValueFrom}. Will be removed in v8. Details: https://rxjs.dev/deprecations/to-promise */
|
|
119
|
+
toPromise(PromiseCtor: PromiseConstructorLike): Promise<T | undefined>;
|
|
120
|
+
}
|
|
121
|
+
//# sourceMappingURL=Observable.d.ts.map
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Subscriber } from './Subscriber';
|
|
2
|
+
import { TeardownLogic } from './types';
|
|
3
|
+
/***
|
|
4
|
+
* @deprecated Internal implementation detail, do not use directly. Will be made internal in v8.
|
|
5
|
+
*/
|
|
6
|
+
export interface Operator<T, R> {
|
|
7
|
+
call(subscriber: Subscriber<R>, source: any): TeardownLogic;
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=Operator.d.ts.map
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { Subject } from './Subject';
|
|
2
|
+
import { TimestampProvider } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* A variant of {@link Subject} that "replays" old values to new subscribers by emitting them when they first subscribe.
|
|
5
|
+
*
|
|
6
|
+
* `ReplaySubject` has an internal buffer that will store a specified number of values that it has observed. Like `Subject`,
|
|
7
|
+
* `ReplaySubject` "observes" values by having them passed to its `next` method. When it observes a value, it will store that
|
|
8
|
+
* value for a time determined by the configuration of the `ReplaySubject`, as passed to its constructor.
|
|
9
|
+
*
|
|
10
|
+
* When a new subscriber subscribes to the `ReplaySubject` instance, it will synchronously emit all values in its buffer in
|
|
11
|
+
* a First-In-First-Out (FIFO) manner. The `ReplaySubject` will also complete, if it has observed completion; and it will
|
|
12
|
+
* error if it has observed an error.
|
|
13
|
+
*
|
|
14
|
+
* There are two main configuration items to be concerned with:
|
|
15
|
+
*
|
|
16
|
+
* 1. `bufferSize` - This will determine how many items are stored in the buffer, defaults to infinite.
|
|
17
|
+
* 2. `windowTime` - The amount of time to hold a value in the buffer before removing it from the buffer.
|
|
18
|
+
*
|
|
19
|
+
* Both configurations may exist simultaneously. So if you would like to buffer a maximum of 3 values, as long as the values
|
|
20
|
+
* are less than 2 seconds old, you could do so with a `new ReplaySubject(3, 2000)`.
|
|
21
|
+
*
|
|
22
|
+
* ### Differences with BehaviorSubject
|
|
23
|
+
*
|
|
24
|
+
* `BehaviorSubject` is similar to `new ReplaySubject(1)`, with a couple of exceptions:
|
|
25
|
+
*
|
|
26
|
+
* 1. `BehaviorSubject` comes "primed" with a single value upon construction.
|
|
27
|
+
* 2. `ReplaySubject` will replay values, even after observing an error, where `BehaviorSubject` will not.
|
|
28
|
+
*
|
|
29
|
+
* @see {@link Subject}
|
|
30
|
+
* @see {@link BehaviorSubject}
|
|
31
|
+
* @see {@link shareReplay}
|
|
32
|
+
*/
|
|
33
|
+
export declare class ReplaySubject<T> extends Subject<T> {
|
|
34
|
+
private _bufferSize;
|
|
35
|
+
private _windowTime;
|
|
36
|
+
private _timestampProvider;
|
|
37
|
+
private _buffer;
|
|
38
|
+
private _infiniteTimeWindow;
|
|
39
|
+
/**
|
|
40
|
+
* @param _bufferSize The size of the buffer to replay on subscription
|
|
41
|
+
* @param _windowTime The amount of time the buffered items will stay buffered
|
|
42
|
+
* @param _timestampProvider An object with a `now()` method that provides the current timestamp. This is used to
|
|
43
|
+
* calculate the amount of time something has been buffered.
|
|
44
|
+
*/
|
|
45
|
+
constructor(_bufferSize?: number, _windowTime?: number, _timestampProvider?: TimestampProvider);
|
|
46
|
+
next(value: T): void;
|
|
47
|
+
private _trimBuffer;
|
|
48
|
+
}
|
|
49
|
+
//# sourceMappingURL=ReplaySubject.d.ts.map
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { Action } from './scheduler/Action';
|
|
2
|
+
import { Subscription } from './Subscription';
|
|
3
|
+
import { SchedulerLike, SchedulerAction } from './types';
|
|
4
|
+
/**
|
|
5
|
+
* An execution context and a data structure to order tasks and schedule their
|
|
6
|
+
* execution. Provides a notion of (potentially virtual) time, through the
|
|
7
|
+
* `now()` getter method.
|
|
8
|
+
*
|
|
9
|
+
* Each unit of work in a Scheduler is called an `Action`.
|
|
10
|
+
*
|
|
11
|
+
* ```ts
|
|
12
|
+
* class Scheduler {
|
|
13
|
+
* now(): number;
|
|
14
|
+
* schedule(work, delay?, state?): Subscription;
|
|
15
|
+
* }
|
|
16
|
+
* ```
|
|
17
|
+
*
|
|
18
|
+
* @deprecated Scheduler is an internal implementation detail of RxJS, and
|
|
19
|
+
* should not be used directly. Rather, create your own class and implement
|
|
20
|
+
* {@link SchedulerLike}. Will be made internal in v8.
|
|
21
|
+
*/
|
|
22
|
+
export declare class Scheduler implements SchedulerLike {
|
|
23
|
+
private schedulerActionCtor;
|
|
24
|
+
static now: () => number;
|
|
25
|
+
constructor(schedulerActionCtor: typeof Action, now?: () => number);
|
|
26
|
+
/**
|
|
27
|
+
* A getter method that returns a number representing the current time
|
|
28
|
+
* (at the time this function was called) according to the scheduler's own
|
|
29
|
+
* internal clock.
|
|
30
|
+
* @return A number that represents the current time. May or may not
|
|
31
|
+
* have a relation to wall-clock time. May or may not refer to a time unit
|
|
32
|
+
* (e.g. milliseconds).
|
|
33
|
+
*/
|
|
34
|
+
now: () => number;
|
|
35
|
+
/**
|
|
36
|
+
* Schedules a function, `work`, for execution. May happen at some point in
|
|
37
|
+
* the future, according to the `delay` parameter, if specified. May be passed
|
|
38
|
+
* some context object, `state`, which will be passed to the `work` function.
|
|
39
|
+
*
|
|
40
|
+
* The given arguments will be processed an stored as an Action object in a
|
|
41
|
+
* queue of actions.
|
|
42
|
+
*
|
|
43
|
+
* @param work A function representing a task, or some unit of work to be
|
|
44
|
+
* executed by the Scheduler.
|
|
45
|
+
* @param delay Time to wait before executing the work, where the time unit is
|
|
46
|
+
* implicit and defined by the Scheduler itself.
|
|
47
|
+
* @param state Some contextual data that the `work` function uses when called
|
|
48
|
+
* by the Scheduler.
|
|
49
|
+
* @return A subscription in order to be able to unsubscribe the scheduled work.
|
|
50
|
+
*/
|
|
51
|
+
schedule<T>(work: (this: SchedulerAction<T>, state?: T) => void, delay?: number, state?: T): Subscription;
|
|
52
|
+
}
|
|
53
|
+
//# sourceMappingURL=Scheduler.d.ts.map
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { Operator } from './Operator';
|
|
2
|
+
import { Observable } from './Observable';
|
|
3
|
+
import { Observer, SubscriptionLike } from './types';
|
|
4
|
+
/**
|
|
5
|
+
* A Subject is a special type of Observable that allows values to be
|
|
6
|
+
* multicasted to many Observers. Subjects are like EventEmitters.
|
|
7
|
+
*
|
|
8
|
+
* Every Subject is an Observable and an Observer. You can subscribe to a
|
|
9
|
+
* Subject, and you can call next to feed values as well as error and complete.
|
|
10
|
+
*/
|
|
11
|
+
export declare class Subject<T> extends Observable<T> implements SubscriptionLike {
|
|
12
|
+
closed: boolean;
|
|
13
|
+
private currentObservers;
|
|
14
|
+
/** @deprecated Internal implementation detail, do not use directly. Will be made internal in v8. */
|
|
15
|
+
observers: Observer<T>[];
|
|
16
|
+
/** @deprecated Internal implementation detail, do not use directly. Will be made internal in v8. */
|
|
17
|
+
isStopped: boolean;
|
|
18
|
+
/** @deprecated Internal implementation detail, do not use directly. Will be made internal in v8. */
|
|
19
|
+
hasError: boolean;
|
|
20
|
+
/** @deprecated Internal implementation detail, do not use directly. Will be made internal in v8. */
|
|
21
|
+
thrownError: any;
|
|
22
|
+
/**
|
|
23
|
+
* Creates a "subject" by basically gluing an observer to an observable.
|
|
24
|
+
*
|
|
25
|
+
* @deprecated Recommended you do not use. Will be removed at some point in the future. Plans for replacement still under discussion.
|
|
26
|
+
*/
|
|
27
|
+
static create: (...args: any[]) => any;
|
|
28
|
+
constructor();
|
|
29
|
+
/** @deprecated Internal implementation detail, do not use directly. Will be made internal in v8. */
|
|
30
|
+
lift<R>(operator: Operator<T, R>): Observable<R>;
|
|
31
|
+
next(value: T): void;
|
|
32
|
+
error(err: any): void;
|
|
33
|
+
complete(): void;
|
|
34
|
+
unsubscribe(): void;
|
|
35
|
+
get observed(): boolean;
|
|
36
|
+
/**
|
|
37
|
+
* Creates a new Observable with this Subject as the source. You can do this
|
|
38
|
+
* to create custom Observer-side logic of the Subject and conceal it from
|
|
39
|
+
* code that uses the Observable.
|
|
40
|
+
* @return Observable that this Subject casts to.
|
|
41
|
+
*/
|
|
42
|
+
asObservable(): Observable<T>;
|
|
43
|
+
}
|
|
44
|
+
export declare class AnonymousSubject<T> extends Subject<T> {
|
|
45
|
+
/** @deprecated Internal implementation detail, do not use directly. Will be made internal in v8. */
|
|
46
|
+
destination?: Observer<T> | undefined;
|
|
47
|
+
constructor(
|
|
48
|
+
/** @deprecated Internal implementation detail, do not use directly. Will be made internal in v8. */
|
|
49
|
+
destination?: Observer<T> | undefined, source?: Observable<T>);
|
|
50
|
+
next(value: T): void;
|
|
51
|
+
error(err: any): void;
|
|
52
|
+
complete(): void;
|
|
53
|
+
}
|
|
54
|
+
//# sourceMappingURL=Subject.d.ts.map
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import { Observer } from './types';
|
|
2
|
+
import { Subscription } from './Subscription';
|
|
3
|
+
/**
|
|
4
|
+
* Implements the {@link Observer} interface and extends the
|
|
5
|
+
* {@link Subscription} class. While the {@link Observer} is the public API for
|
|
6
|
+
* consuming the values of an {@link Observable}, all Observers get converted to
|
|
7
|
+
* a Subscriber, in order to provide Subscription-like capabilities such as
|
|
8
|
+
* `unsubscribe`. Subscriber is a common type in RxJS, and crucial for
|
|
9
|
+
* implementing operators, but it is rarely used as a public API.
|
|
10
|
+
*/
|
|
11
|
+
export declare class Subscriber<T> extends Subscription implements Observer<T> {
|
|
12
|
+
/**
|
|
13
|
+
* A static factory for a Subscriber, given a (potentially partial) definition
|
|
14
|
+
* of an Observer.
|
|
15
|
+
* @param next The `next` callback of an Observer.
|
|
16
|
+
* @param error The `error` callback of an
|
|
17
|
+
* Observer.
|
|
18
|
+
* @param complete The `complete` callback of an
|
|
19
|
+
* Observer.
|
|
20
|
+
* @return A Subscriber wrapping the (partially defined)
|
|
21
|
+
* Observer represented by the given arguments.
|
|
22
|
+
* @deprecated Do not use. Will be removed in v8. There is no replacement for this
|
|
23
|
+
* method, and there is no reason to be creating instances of `Subscriber` directly.
|
|
24
|
+
* If you have a specific use case, please file an issue.
|
|
25
|
+
*/
|
|
26
|
+
static create<T>(next?: (x?: T) => void, error?: (e?: any) => void, complete?: () => void): Subscriber<T>;
|
|
27
|
+
/** @deprecated Internal implementation detail, do not use directly. Will be made internal in v8. */
|
|
28
|
+
protected isStopped: boolean;
|
|
29
|
+
/** @deprecated Internal implementation detail, do not use directly. Will be made internal in v8. */
|
|
30
|
+
protected destination: Subscriber<any> | Observer<any>;
|
|
31
|
+
/**
|
|
32
|
+
* @deprecated Internal implementation detail, do not use directly. Will be made internal in v8.
|
|
33
|
+
* There is no reason to directly create an instance of Subscriber. This type is exported for typings reasons.
|
|
34
|
+
*/
|
|
35
|
+
constructor(destination?: Subscriber<any> | Observer<any>);
|
|
36
|
+
/**
|
|
37
|
+
* The {@link Observer} callback to receive notifications of type `next` from
|
|
38
|
+
* the Observable, with a value. The Observable may call this method 0 or more
|
|
39
|
+
* times.
|
|
40
|
+
* @param value The `next` value.
|
|
41
|
+
*/
|
|
42
|
+
next(value: T): void;
|
|
43
|
+
/**
|
|
44
|
+
* The {@link Observer} callback to receive notifications of type `error` from
|
|
45
|
+
* the Observable, with an attached `Error`. Notifies the Observer that
|
|
46
|
+
* the Observable has experienced an error condition.
|
|
47
|
+
* @param err The `error` exception.
|
|
48
|
+
*/
|
|
49
|
+
error(err?: any): void;
|
|
50
|
+
/**
|
|
51
|
+
* The {@link Observer} callback to receive a valueless notification of type
|
|
52
|
+
* `complete` from the Observable. Notifies the Observer that the Observable
|
|
53
|
+
* has finished sending push-based notifications.
|
|
54
|
+
*/
|
|
55
|
+
complete(): void;
|
|
56
|
+
unsubscribe(): void;
|
|
57
|
+
protected _next(value: T): void;
|
|
58
|
+
protected _error(err: any): void;
|
|
59
|
+
protected _complete(): void;
|
|
60
|
+
}
|
|
61
|
+
export declare class SafeSubscriber<T> extends Subscriber<T> {
|
|
62
|
+
constructor(observerOrNext?: Partial<Observer<T>> | ((value: T) => void) | null, error?: ((e?: any) => void) | null, complete?: (() => void) | null);
|
|
63
|
+
}
|
|
64
|
+
/**
|
|
65
|
+
* The observer used as a stub for subscriptions where the user did not
|
|
66
|
+
* pass any arguments to `subscribe`. Comes with the default error handling
|
|
67
|
+
* behavior.
|
|
68
|
+
*/
|
|
69
|
+
export declare const EMPTY_OBSERVER: Readonly<Observer<any>> & {
|
|
70
|
+
closed: true;
|
|
71
|
+
};
|
|
72
|
+
//# sourceMappingURL=Subscriber.d.ts.map
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { SubscriptionLike, TeardownLogic } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* Represents a disposable resource, such as the execution of an Observable. A
|
|
4
|
+
* Subscription has one important method, `unsubscribe`, that takes no argument
|
|
5
|
+
* and just disposes the resource held by the subscription.
|
|
6
|
+
*
|
|
7
|
+
* Additionally, subscriptions may be grouped together through the `add()`
|
|
8
|
+
* method, which will attach a child Subscription to the current Subscription.
|
|
9
|
+
* When a Subscription is unsubscribed, all its children (and its grandchildren)
|
|
10
|
+
* will be unsubscribed as well.
|
|
11
|
+
*/
|
|
12
|
+
export declare class Subscription implements SubscriptionLike {
|
|
13
|
+
private initialTeardown?;
|
|
14
|
+
static EMPTY: Subscription;
|
|
15
|
+
/**
|
|
16
|
+
* A flag to indicate whether this Subscription has already been unsubscribed.
|
|
17
|
+
*/
|
|
18
|
+
closed: boolean;
|
|
19
|
+
private _parentage;
|
|
20
|
+
/**
|
|
21
|
+
* The list of registered finalizers to execute upon unsubscription. Adding and removing from this
|
|
22
|
+
* list occurs in the {@link #add} and {@link #remove} methods.
|
|
23
|
+
*/
|
|
24
|
+
private _finalizers;
|
|
25
|
+
/**
|
|
26
|
+
* @param initialTeardown A function executed first as part of the finalization
|
|
27
|
+
* process that is kicked off when {@link #unsubscribe} is called.
|
|
28
|
+
*/
|
|
29
|
+
constructor(initialTeardown?: (() => void) | undefined);
|
|
30
|
+
/**
|
|
31
|
+
* Disposes the resources held by the subscription. May, for instance, cancel
|
|
32
|
+
* an ongoing Observable execution or cancel any other type of work that
|
|
33
|
+
* started when the Subscription was created.
|
|
34
|
+
*/
|
|
35
|
+
unsubscribe(): void;
|
|
36
|
+
/**
|
|
37
|
+
* Adds a finalizer to this subscription, so that finalization will be unsubscribed/called
|
|
38
|
+
* when this subscription is unsubscribed. If this subscription is already {@link #closed},
|
|
39
|
+
* because it has already been unsubscribed, then whatever finalizer is passed to it
|
|
40
|
+
* will automatically be executed (unless the finalizer itself is also a closed subscription).
|
|
41
|
+
*
|
|
42
|
+
* Closed Subscriptions cannot be added as finalizers to any subscription. Adding a closed
|
|
43
|
+
* subscription to a any subscription will result in no operation. (A noop).
|
|
44
|
+
*
|
|
45
|
+
* Adding a subscription to itself, or adding `null` or `undefined` will not perform any
|
|
46
|
+
* operation at all. (A noop).
|
|
47
|
+
*
|
|
48
|
+
* `Subscription` instances that are added to this instance will automatically remove themselves
|
|
49
|
+
* if they are unsubscribed. Functions and {@link Unsubscribable} objects that you wish to remove
|
|
50
|
+
* will need to be removed manually with {@link #remove}
|
|
51
|
+
*
|
|
52
|
+
* @param teardown The finalization logic to add to this subscription.
|
|
53
|
+
*/
|
|
54
|
+
add(teardown: TeardownLogic): void;
|
|
55
|
+
/**
|
|
56
|
+
* Checks to see if a this subscription already has a particular parent.
|
|
57
|
+
* This will signal that this subscription has already been added to the parent in question.
|
|
58
|
+
* @param parent the parent to check for
|
|
59
|
+
*/
|
|
60
|
+
private _hasParent;
|
|
61
|
+
/**
|
|
62
|
+
* Adds a parent to this subscription so it can be removed from the parent if it
|
|
63
|
+
* unsubscribes on it's own.
|
|
64
|
+
*
|
|
65
|
+
* NOTE: THIS ASSUMES THAT {@link _hasParent} HAS ALREADY BEEN CHECKED.
|
|
66
|
+
* @param parent The parent subscription to add
|
|
67
|
+
*/
|
|
68
|
+
private _addParent;
|
|
69
|
+
/**
|
|
70
|
+
* Called on a child when it is removed via {@link #remove}.
|
|
71
|
+
* @param parent The parent to remove
|
|
72
|
+
*/
|
|
73
|
+
private _removeParent;
|
|
74
|
+
/**
|
|
75
|
+
* Removes a finalizer from this subscription that was previously added with the {@link #add} method.
|
|
76
|
+
*
|
|
77
|
+
* Note that `Subscription` instances, when unsubscribed, will automatically remove themselves
|
|
78
|
+
* from every other `Subscription` they have been added to. This means that using the `remove` method
|
|
79
|
+
* is not a common thing and should be used thoughtfully.
|
|
80
|
+
*
|
|
81
|
+
* If you add the same finalizer instance of a function or an unsubscribable object to a `Subscription` instance
|
|
82
|
+
* more than once, you will need to call `remove` the same number of times to remove all instances.
|
|
83
|
+
*
|
|
84
|
+
* All finalizer instances are removed to free up memory upon unsubscription.
|
|
85
|
+
*
|
|
86
|
+
* @param teardown The finalizer to remove from this subscription
|
|
87
|
+
*/
|
|
88
|
+
remove(teardown: Exclude<TeardownLogic, void>): void;
|
|
89
|
+
}
|
|
90
|
+
export declare const EMPTY_SUBSCRIPTION: Subscription;
|
|
91
|
+
export declare function isSubscription(value: any): value is Subscription;
|
|
92
|
+
//# sourceMappingURL=Subscription.d.ts.map
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
import { AjaxRequest, AjaxResponseType } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* A normalized response from an AJAX request. To get the data from the response,
|
|
4
|
+
* you will want to read the `response` property.
|
|
5
|
+
*
|
|
6
|
+
* - DO NOT create instances of this class directly.
|
|
7
|
+
* - DO NOT subclass this class.
|
|
8
|
+
*
|
|
9
|
+
* It is advised not to hold this object in memory, as it has a reference to
|
|
10
|
+
* the original XHR used to make the request, as well as properties containing
|
|
11
|
+
* request and response data.
|
|
12
|
+
*
|
|
13
|
+
* @see {@link ajax}
|
|
14
|
+
* @see {@link AjaxConfig}
|
|
15
|
+
*/
|
|
16
|
+
export declare class AjaxResponse<T> {
|
|
17
|
+
/**
|
|
18
|
+
* The original event object from the raw XHR event.
|
|
19
|
+
*/
|
|
20
|
+
readonly originalEvent: ProgressEvent;
|
|
21
|
+
/**
|
|
22
|
+
* The XMLHttpRequest object used to make the request.
|
|
23
|
+
* NOTE: It is advised not to hold this in memory, as it will retain references to all of it's event handlers
|
|
24
|
+
* and many other things related to the request.
|
|
25
|
+
*/
|
|
26
|
+
readonly xhr: XMLHttpRequest;
|
|
27
|
+
/**
|
|
28
|
+
* The request parameters used to make the HTTP request.
|
|
29
|
+
*/
|
|
30
|
+
readonly request: AjaxRequest;
|
|
31
|
+
/**
|
|
32
|
+
* The event type. This can be used to discern between different events
|
|
33
|
+
* if you're using progress events with {@link includeDownloadProgress} or
|
|
34
|
+
* {@link includeUploadProgress} settings in {@link AjaxConfig}.
|
|
35
|
+
*
|
|
36
|
+
* The event type consists of two parts: the {@link AjaxDirection} and the
|
|
37
|
+
* the event type. Merged with `_`, they form the `type` string. The
|
|
38
|
+
* direction can be an `upload` or a `download` direction, while an event can
|
|
39
|
+
* be `loadstart`, `progress` or `load`.
|
|
40
|
+
*
|
|
41
|
+
* `download_load` is the type of event when download has finished and the
|
|
42
|
+
* response is available.
|
|
43
|
+
*/
|
|
44
|
+
readonly type: AjaxResponseType;
|
|
45
|
+
/** The HTTP status code */
|
|
46
|
+
readonly status: number;
|
|
47
|
+
/**
|
|
48
|
+
* The response data, if any. Note that this will automatically be converted to the proper type
|
|
49
|
+
*/
|
|
50
|
+
readonly response: T;
|
|
51
|
+
/**
|
|
52
|
+
* The responseType set on the request. (For example: `""`, `"arraybuffer"`, `"blob"`, `"document"`, `"json"`, or `"text"`)
|
|
53
|
+
* @deprecated There isn't much reason to examine this. It's the same responseType set (or defaulted) on the ajax config.
|
|
54
|
+
* If you really need to examine this value, you can check it on the `request` or the `xhr`. Will be removed in v8.
|
|
55
|
+
*/
|
|
56
|
+
readonly responseType: XMLHttpRequestResponseType;
|
|
57
|
+
/**
|
|
58
|
+
* The total number of bytes loaded so far. To be used with {@link total} while
|
|
59
|
+
* calculating progress. (You will want to set {@link includeDownloadProgress} or
|
|
60
|
+
* {@link includeDownloadProgress})
|
|
61
|
+
*/
|
|
62
|
+
readonly loaded: number;
|
|
63
|
+
/**
|
|
64
|
+
* The total number of bytes to be loaded. To be used with {@link loaded} while
|
|
65
|
+
* calculating progress. (You will want to set {@link includeDownloadProgress} or
|
|
66
|
+
* {@link includeDownloadProgress})
|
|
67
|
+
*/
|
|
68
|
+
readonly total: number;
|
|
69
|
+
/**
|
|
70
|
+
* A dictionary of the response headers.
|
|
71
|
+
*/
|
|
72
|
+
readonly responseHeaders: Record<string, string>;
|
|
73
|
+
/**
|
|
74
|
+
* A normalized response from an AJAX request. To get the data from the response,
|
|
75
|
+
* you will want to read the `response` property.
|
|
76
|
+
*
|
|
77
|
+
* - DO NOT create instances of this class directly.
|
|
78
|
+
* - DO NOT subclass this class.
|
|
79
|
+
*
|
|
80
|
+
* @param originalEvent The original event object from the XHR `onload` event.
|
|
81
|
+
* @param xhr The `XMLHttpRequest` object used to make the request. This is useful for examining status code, etc.
|
|
82
|
+
* @param request The request settings used to make the HTTP request.
|
|
83
|
+
* @param type The type of the event emitted by the {@link ajax} Observable
|
|
84
|
+
*/
|
|
85
|
+
constructor(
|
|
86
|
+
/**
|
|
87
|
+
* The original event object from the raw XHR event.
|
|
88
|
+
*/
|
|
89
|
+
originalEvent: ProgressEvent,
|
|
90
|
+
/**
|
|
91
|
+
* The XMLHttpRequest object used to make the request.
|
|
92
|
+
* NOTE: It is advised not to hold this in memory, as it will retain references to all of it's event handlers
|
|
93
|
+
* and many other things related to the request.
|
|
94
|
+
*/
|
|
95
|
+
xhr: XMLHttpRequest,
|
|
96
|
+
/**
|
|
97
|
+
* The request parameters used to make the HTTP request.
|
|
98
|
+
*/
|
|
99
|
+
request: AjaxRequest,
|
|
100
|
+
/**
|
|
101
|
+
* The event type. This can be used to discern between different events
|
|
102
|
+
* if you're using progress events with {@link includeDownloadProgress} or
|
|
103
|
+
* {@link includeUploadProgress} settings in {@link AjaxConfig}.
|
|
104
|
+
*
|
|
105
|
+
* The event type consists of two parts: the {@link AjaxDirection} and the
|
|
106
|
+
* the event type. Merged with `_`, they form the `type` string. The
|
|
107
|
+
* direction can be an `upload` or a `download` direction, while an event can
|
|
108
|
+
* be `loadstart`, `progress` or `load`.
|
|
109
|
+
*
|
|
110
|
+
* `download_load` is the type of event when download has finished and the
|
|
111
|
+
* response is available.
|
|
112
|
+
*/
|
|
113
|
+
type?: AjaxResponseType);
|
|
114
|
+
}
|
|
115
|
+
//# sourceMappingURL=AjaxResponse.d.ts.map
|