From f5090b49c3ffd3b235cfbe6096fba3ad0536ebf3 Mon Sep 17 00:00:00 2001 From: OJ Kwon Date: Thu, 28 Apr 2016 01:07:43 -0700 Subject: [PATCH] fix(Rx): remove kitchenSink and DOM, let Rx export all closes #1650 BREAKING CHANGE: `Rx.kitchenSink` and `Rx.DOM` are removed, `Rx` export everything. --- .github/PULL_REQUEST_TEMPLATE.md | 2 +- doc/operator-creation.md | 40 +++++++++---------- doc/scripts/setup-rx-script.js | 5 --- esdoc.json | 5 +-- index.js | 2 +- package.json | 16 ++++---- .../operators/distinct-keyselector.js | 2 +- .../immediate-scheduler/operators/distinct.js | 2 +- spec/helpers/test-helper.ts | 2 +- spec/helpers/testScheduler-ui.ts | 2 +- spec/helpers/tests2png/diagram-test-runner.js | 2 +- spec/observables/IteratorObservable-spec.ts | 2 +- spec/observables/ScalarObservable-spec.ts | 2 +- .../observables/SubscribeOnObservable-spec.ts | 2 +- spec/observables/bindCallback-spec.ts | 2 +- spec/observables/bindNodeCallback-spec.ts | 2 +- spec/observables/combineLatest-spec.ts | 2 +- spec/observables/concat-spec.ts | 2 +- spec/observables/dom/ajax-spec.ts | 2 +- spec/observables/dom/webSocket-spec.ts | 2 +- spec/observables/forkJoin-spec.ts | 2 +- spec/observables/from-spec.ts | 2 +- spec/observables/fromEvent-spec.ts | 2 +- spec/observables/fromEventPattern-spec.ts | 2 +- spec/observables/generate-spec.ts | 2 +- spec/observables/if-spec.ts | 2 +- spec/observables/interval-spec.ts | 2 +- spec/observables/merge-spec.ts | 2 +- spec/observables/of-spec.ts | 2 +- spec/observables/range-spec.ts | 2 +- spec/observables/throw-spec.ts | 2 +- spec/observables/timer-spec.ts | 2 +- spec/observables/using-spec.ts | 2 +- spec/operators/auditTime-spec.ts | 2 +- spec/operators/bufferTime-spec.ts | 2 +- spec/operators/cache-spec.ts | 2 +- spec/operators/catch-spec.ts | 2 +- spec/operators/concat-spec.ts | 2 +- spec/operators/concatAll-spec.ts | 2 +- spec/operators/debounce-spec.ts | 2 +- spec/operators/debounceTime-spec.ts | 2 +- spec/operators/delay-spec.ts | 2 +- spec/operators/delayWhen-spec.ts | 2 +- .../operators/distinctUntilKeyChanged-spec.ts | 2 +- spec/operators/elementAt-spec.ts | 2 +- spec/operators/exhaust-spec.ts | 2 +- spec/operators/exhaustMap-spec.ts | 2 +- spec/operators/finally-spec.ts | 2 +- spec/operators/find-spec.ts | 2 +- spec/operators/findIndex-spec.ts | 2 +- spec/operators/groupBy-spec.ts | 2 +- spec/operators/isEmpty-spec.ts | 2 +- spec/operators/max-spec.ts | 2 +- spec/operators/merge-spec.ts | 2 +- spec/operators/mergeScan-spec.ts | 2 +- spec/operators/observeOn-spec.ts | 2 +- spec/operators/repeat-spec.ts | 2 +- spec/operators/sampleTime-spec.ts | 2 +- spec/operators/startWith-spec.ts | 2 +- spec/operators/subscribeOn-spec.ts | 2 +- spec/operators/throttleTime-spec.ts | 2 +- spec/operators/timeInterval-spec.ts | 2 +- spec/operators/timeout-spec.ts | 2 +- spec/operators/timeoutWith-spec.ts | 2 +- spec/operators/timestamp-spec.ts | 2 +- spec/operators/window-spec.ts | 2 +- spec/operators/windowCount-spec.ts | 2 +- spec/operators/windowTime-spec.ts | 2 +- spec/operators/windowToggle-spec.ts | 2 +- spec/operators/windowWhen-spec.ts | 2 +- spec/schedulers/AsapScheduler-spec.ts | 2 +- spec/schedulers/TestScheduler-spec.ts | 2 +- spec/schedulers/VirtualTimeScheduler-spec.ts | 2 +- src/Rx.DOM.ts | 25 ------------ src/Rx.KitchenSink.ts | 28 ------------- src/Rx.ts | 31 +++++++++++++- tools/check-gzip-size.js | 3 +- tools/make-system-bundle.js | 1 - tools/make-umd-bundle.js | 7 ---- tsconfig.json | 4 +- 80 files changed, 130 insertions(+), 173 deletions(-) delete mode 100644 doc/scripts/setup-rx-script.js delete mode 100644 src/Rx.DOM.ts delete mode 100644 src/Rx.KitchenSink.ts diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index e293fb94ca..a5f71a4b43 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -3,7 +3,7 @@ Thank you very much for your pull request! If your PR is the addition of a new operator, please make sure all these boxes are ticked with an x: -- [ ] Add the operator to either Core or KitchenSink +- [ ] Add the operator to Rx - [ ] It must have a `-spec.ts` tests file covering the canonical corner cases, with marble diagram tests - [ ] If possible, write a `asDiagram` test case too, for PNG diagram generation purposes - [ ] The spec file should have a type definition test at the end of the spec to verify type definition for various use cases diff --git a/doc/operator-creation.md b/doc/operator-creation.md index 542a2db18d..4f53366b39 100644 --- a/doc/operator-creation.md +++ b/doc/operator-creation.md @@ -1,7 +1,7 @@ # Operator Creation -There are many ways to create an operator for RxJS. In this version of RxJS, performance was the primary consideration, as such, operator creation -in a way that adheres to the existing structures in this library may not be straight forward. This is an attempt to document how to +There are many ways to create an operator for RxJS. In this version of RxJS, performance was the primary consideration, as such, operator creation +in a way that adheres to the existing structures in this library may not be straight forward. This is an attempt to document how to create an operator either for yourself, or for this library. For how to develop a custom operator for *this* library, [see below](#advanced). @@ -11,20 +11,20 @@ For how to develop a custom operator for *this* library, [see below](#advanced). ### Guidelines -In the most common case, users might like to create an operator to be used only by their app. These can be developed in +In the most common case, users might like to create an operator to be used only by their app. These can be developed in any way the developer sees fit, but here are some guidelines: 1. __Operators should always return an Observable__. You're performing operations on unknown sets of things to create new sets. It only makes sense to return a new set. If you create a method that returns something other than an Observable, it's not an operator, and that's fine. 2. __Be sure to manage subscriptions__ created inside of the Observable your operator returns. Your operator is going to have to - subscribe to the source (or `this`) inside of the returned Observable, be sure that it's returned as part of unsubscribe handler or + subscribe to the source (or `this`) inside of the returned Observable, be sure that it's returned as part of unsubscribe handler or subscription. -3. __Be sure to handle exceptions from passed functions__. If you're implementing an operator that takes a function as an argument, +3. __Be sure to handle exceptions from passed functions__. If you're implementing an operator that takes a function as an argument, when you call it, you'll want to wrap it in a `try/catch` and send the error down the `error()` path on the observable. 4. __Be sure to teardown scarce resources__ in your unsubscribe handler of your returned Observable. If you're setting up event handlers or a web socket, or something like that, the unsubscribe handler is a great place to remove that event handler or close that socket. - + @@ -36,7 +36,7 @@ function mySimpleOperator(someCallback) { return Observable.create(subscriber => { // because we're in an arrow function `this` is from the outer scope. var source = this; - + // save our inner subscription var subscription = source.subscribe(value => { // important: catch errors from user-provided callbacks @@ -45,12 +45,12 @@ function mySimpleOperator(someCallback) { } catch(err) { subscriber.error(err); } - }, + }, // be sure to handle errors and completions as appropriate and // send them along err => subscriber.error(err), () => subscriber.complete()); - + // to return now return subscription; }); @@ -77,10 +77,10 @@ class MyObservable extends Observable { observable.operator = operator; return observable; } - + // put it here .. or .. customOperator() { - /* do things and return an Observable */ + /* do things and return an Observable */ } } @@ -101,11 +101,11 @@ someObservable.mySimpleOperator(x => x + '!'); ## Creating An Operator For Inclusion In *This* Library -__To create an operator for inclusion in this library, it's probably best to work from prior art__. Something +__To create an operator for inclusion in this library, it's probably best to work from prior art__. Something like the `filter` operator would be a good start. It's not expected that you'll be able to read this section and suddenly be an expert operator contributor. -**If you find yourself confused, DO NOT worry. Follow prior examples in the repo, submit a PR, and we'll work with you.** +**If you find yourself confused, DO NOT worry. Follow prior examples in the repo, submit a PR, and we'll work with you.** Hopefully the information provided here will give context to decisions made while developing operators in this library. There are a few things to know and (try to) understand while developing operators: @@ -114,15 +114,15 @@ There are a few things to know and (try to) understand while developing operator "build their own observable" by pulling in operator methods an adding them to observable in their own module. It also means operators can be brought in ad-hock and used directly, either with the ES7 function bind operator in Babel (`::`) or by using it with `.call()`. -2. Every operator has an `Operator` class. The `Operator` class is really a `Subscriber` "factory". It's - what gets passed into the `lift` method to make the "magic" happen. It's sole job is to create the operation's +2. Every operator has an `Operator` class. The `Operator` class is really a `Subscriber` "factory". It's + what gets passed into the `lift` method to make the "magic" happen. It's sole job is to create the operation's `Subscriber` instance on subscription. -3. Every operator has a `Subscriber` class. This class does *all* of the logic for the operation. It's job is to - handle values being nexted in (generally by overriding `_next()`) and forward it along to the `destination`, +3. Every operator has a `Subscriber` class. This class does *all* of the logic for the operation. It's job is to + handle values being nexted in (generally by overriding `_next()`) and forward it along to the `destination`, which is the next observer in the chain. - It's important to note that the `destination` Observer set on any `Subscriber` serves as more than just the destinations for the events passing through, If the `destination` is a `Subscriber` it also is used to set up - a shared underlying `Subscription`, which, in fact, is also a `Subscriber`, and is the first `Subscriber` in the + a shared underlying `Subscription`, which, in fact, is also a `Subscriber`, and is the first `Subscriber` in the chain. - Subscribers all have `add` and `remove` methods that are used for adding and removing inner subscriptions to the shared underlying subscription. @@ -133,7 +133,7 @@ There are a few things to know and (try to) understand while developing operator Please complete these steps for each new operator added to RxJS as a pull request: -- Add the operator to either Core or KitchenSink +- Add the operator to Rx - It must have a `-spec.ts` tests file covering the canonical corner cases, with marble diagram tests - If possible, write a `asDiagram` test case too, for PNG diagram generation purposes - The spec file should have a type definition test at the end of the spec to verify type definition for various use cases @@ -152,7 +152,7 @@ for their `unsubscribe` calls. Meaning if you call `unsubscribe` on them, it mig not to set the `destination` of inner subscriptions. An example of this might be the switch operators, that have a single underlying inner subscription that needs to unsubscribe independent of the main subscription. -If you find yourself creating inner subscriptions, it might also be worth checking to see if the observable being passed `_isScalar`, +If you find yourself creating inner subscriptions, it might also be worth checking to see if the observable being passed `_isScalar`, because if it is, you can pull the `value` out of it directly and improve the performance of your operator when it's operating over scalar observables. For reference a scalar observable is any observable that has a single static value underneath it. `Observable.of('foo')` will return a `ScalarObservable`, likewise, resolved `PromiseObservable`s will act as scalars. diff --git a/doc/scripts/setup-rx-script.js b/doc/scripts/setup-rx-script.js deleted file mode 100644 index 7184d2a1f2..0000000000 --- a/doc/scripts/setup-rx-script.js +++ /dev/null @@ -1,5 +0,0 @@ -(function () { - if (Rx.KitchenSink) { - Rx = Rx.KitchenSink; - } -})(); diff --git a/esdoc.json b/esdoc.json index fda2537d83..0c6816a6e2 100644 --- a/esdoc.json +++ b/esdoc.json @@ -10,11 +10,10 @@ "title": "RxJS", "styles": ["./doc/styles/main.css"], "scripts": [ - "./dist/global/Rx.KitchenSink.umd.js", + "./dist/global/Rx.umd.js", "./doc/asset/devtools-welcome.js", "./doc/scripts/custom-manual-styles.js", - "./doc/decision-tree-widget/dist/decision-tree-widget.min.js", - "./doc/scripts/setup-rx-script.js" + "./doc/decision-tree-widget/dist/decision-tree-widget.min.js" ], "index": "./doc/index.md", "plugins": [ diff --git a/index.js b/index.js index 84e8697c36..ddeed3a1ab 100644 --- a/index.js +++ b/index.js @@ -1 +1 @@ -module.exports = require('./dist/cjs/Rx.KitchenSink'); +module.exports = require('./dist/cjs/Rx'); diff --git a/package.json b/package.json index 1ae0e333ac..2a74b05de5 100644 --- a/package.json +++ b/package.json @@ -18,8 +18,7 @@ "build_cjs": "Build CJS package with clean up existing build, copy source into dist", "build_es6": "Build ES6 package with clean up existing build, copy source into dist", "build_closure_core": "Minify Global core build using closure compiler", - "build_closure_kitchensink": "Minify Global kitchenSink build using closure compiler", - "build_global": "Build Global package, then minify core & kitchensink build", + "build_global": "Build Global package, then minify build", "build_perf": "Build CJS & Global build, run macro performance test", "build_test": "Build CJS package & test spec, execute mocha test runner", "build_cover": "Run lint to current code, build CJS & test spec, execute test coverage", @@ -55,8 +54,7 @@ "build_es6": "npm-run-all clean_dist_es6 copy_src_es6 compile_dist_es6", "build_es6_for_docs": "npm-run-all clean_dist_es6 copy_src_es6 compile_dist_es6_for_docs", "build_closure_core": "java -jar ./node_modules/google-closure-compiler/compiler.jar --js ./dist/global/Rx.umd.js --language_in ECMASCRIPT5 --create_source_map ./dist/global/Rx.umd.min.js.map --js_output_file ./dist/global/Rx.umd.min.js", - "build_closure_kitchensink": "java -jar ./node_modules/google-closure-compiler/compiler.jar --js ./dist/global/Rx.KitchenSink.umd.js --language_in ECMASCRIPT5 --create_source_map ./dist/global/Rx.KitchenSink.umd.min.js.map --js_output_file ./dist/global/Rx.KitchenSink.umd.min.js", - "build_global": "rm -rf ./dist/global && mkdirp ./dist/global && node tools/make-umd-bundle.js && node tools/make-system-bundle.js && npm-run-all build_closure_core build_closure_kitchensink", + "build_global": "rm -rf ./dist/global && mkdirp ./dist/global && node tools/make-umd-bundle.js && node tools/make-system-bundle.js && npm-run-all build_closure_core", "build_perf": "webdriver-manager update && npm-run-all build_cjs build_global perf", "build_test": "rm -rf ./dist/ && npm-run-all lint build_cjs clean_spec build_spec test_mocha", "build_cover": "rm -rf ./dist/ && npm-run-all lint build_cjs build_spec cover", @@ -72,12 +70,12 @@ "copy_src_cjs": "mkdirp ./dist/cjs/src && cp -r ./src/* ./dist/cjs/src", "copy_src_es6": "mkdirp ./dist/es6/src && cp -r ./src/* ./dist/es6/src", "commit": "git-cz", - "compile_dist_amd": "tsc typings/main/ambient/es6-shim/index.d.ts ./dist/amd/src/Rx.ts ./dist/amd/src/Rx.KitchenSink.ts ./dist/amd/src/Rx.DOM.ts ./dist/amd/src/add/observable/of.ts -m amd --sourceMap --outDir ./dist/amd --target ES5 --diagnostics --pretty --noImplicitAny --suppressImplicitAnyIndexErrors --moduleResolution node", - "compile_dist_cjs": "tsc typings/main/ambient/es6-shim/index.d.ts ./dist/cjs/src/Rx.ts ./dist/cjs/src/Rx.KitchenSink.ts ./dist/cjs/src/Rx.DOM.ts ./dist/cjs/src/add/observable/of.ts -m commonjs --sourceMap --outDir ./dist/cjs --target ES5 -d --diagnostics --pretty --noImplicitAny --suppressImplicitAnyIndexErrors --moduleResolution node", - "compile_dist_es6": "tsc ./dist/es6/src/Rx.ts ./dist/es6/src/Rx.KitchenSink.ts ./dist/es6/src/Rx.DOM.ts ./dist/es6/src/add/observable/of.ts -m es2015 --sourceMap --outDir ./dist/es6 --target ES6 -d --diagnostics --pretty --noImplicitAny --suppressImplicitAnyIndexErrors --moduleResolution node", - "compile_dist_es6_for_docs": "tsc ./dist/es6/src/Rx.ts ./dist/es6/src/Rx.KitchenSink.ts ./dist/es6/src/Rx.DOM.ts ./dist/es6/src/add/observable/of.ts ./dist/es6/src/MiscJSDoc.ts -m es2015 --sourceMap --outDir ./dist/es6 --target ES6 -d --diagnostics --pretty --noImplicitAny --suppressImplicitAnyIndexErrors --moduleResolution node", + "compile_dist_amd": "tsc typings/main/ambient/es6-shim/index.d.ts ./dist/amd/src/Rx.ts ./dist/amd/src/add/observable/of.ts -m amd --sourceMap --outDir ./dist/amd --target ES5 --diagnostics --pretty --noImplicitAny --suppressImplicitAnyIndexErrors --moduleResolution node", + "compile_dist_cjs": "tsc typings/main/ambient/es6-shim/index.d.ts ./dist/cjs/src/Rx.ts ./dist/cjs/src/add/observable/of.ts -m commonjs --sourceMap --outDir ./dist/cjs --target ES5 -d --diagnostics --pretty --noImplicitAny --suppressImplicitAnyIndexErrors --moduleResolution node", + "compile_dist_es6": "tsc ./dist/es6/src/Rx.ts ./dist/es6/src/add/observable/of.ts -m es2015 --sourceMap --outDir ./dist/es6 --target ES6 -d --diagnostics --pretty --noImplicitAny --suppressImplicitAnyIndexErrors --moduleResolution node", + "compile_dist_es6_for_docs": "tsc ./dist/es6/src/Rx.ts ./dist/es6/src/add/observable/of.ts ./dist/es6/src/MiscJSDoc.ts -m es2015 --sourceMap --outDir ./dist/es6 --target ES6 -d --diagnostics --pretty --noImplicitAny --suppressImplicitAnyIndexErrors --moduleResolution node", "cover": "npm-run-all cover_test cover_remapping", - "cover_test": "rm -rf dist/cjs && tsc typings/main/ambient/es6-shim/index.d.ts src/Rx.ts src/Rx.KitchenSink.ts src/Rx.DOM.ts src/add/observable/of.ts -m commonjs --outDir dist/cjs --sourceMap --target ES5 -d && istanbul cover -x \"spec-js/**/*\" -x \"mocha-setup-node.js\" ./node_modules/mocha/bin/_mocha -- --opts spec/support/default.opts spec-js", + "cover_test": "rm -rf dist/cjs && tsc typings/main/ambient/es6-shim/index.d.ts src/Rx.ts src/add/observable/of.ts -m commonjs --outDir dist/cjs --sourceMap --target ES5 -d && istanbul cover -x \"spec-js/**/*\" -x \"mocha-setup-node.js\" ./node_modules/mocha/bin/_mocha -- --opts spec/support/default.opts spec-js", "cover_remapping": "remap-istanbul -i coverage/coverage.json -o coverage/coverage-remapped.json && remap-istanbul -i coverage/coverage.json -o coverage/coverage-remapped.lcov -t lcovonly && remap-istanbul -i coverage/coverage.json -o coverage/coverage-remapped -t html", "decision_tree_widget": "cd doc/decision-tree-widget && npm run build && cd ../..", "generate_packages": "node .make-packages.js", diff --git a/perf/micro/immediate-scheduler/operators/distinct-keyselector.js b/perf/micro/immediate-scheduler/operators/distinct-keyselector.js index ba3c74eba1..86afd4aeb8 100644 --- a/perf/micro/immediate-scheduler/operators/distinct-keyselector.js +++ b/perf/micro/immediate-scheduler/operators/distinct-keyselector.js @@ -1,5 +1,5 @@ var RxOld = require('rx'); -var RxNew = require('../../../../dist/cjs/Rx.KitchenSink'); +var RxNew = require('../../../../dist/cjs/Rx'); module.exports = function (suite) { var source = Array.from({ length: 25 }, function (_, i) { return { value: i % 3 }; }); diff --git a/perf/micro/immediate-scheduler/operators/distinct.js b/perf/micro/immediate-scheduler/operators/distinct.js index 0790f650db..fee8a7eb84 100644 --- a/perf/micro/immediate-scheduler/operators/distinct.js +++ b/perf/micro/immediate-scheduler/operators/distinct.js @@ -1,5 +1,5 @@ var RxOld = require('rx'); -var RxNew = require('../../../../dist/cjs/Rx.KitchenSink'); +var RxNew = require('../../../../dist/cjs/Rx'); module.exports = function (suite) { var source = Array.from({ length: 25 }, function (_, i) { return i % 3; }); diff --git a/spec/helpers/test-helper.ts b/spec/helpers/test-helper.ts index 7b246e1e1e..bd0d80998c 100644 --- a/spec/helpers/test-helper.ts +++ b/spec/helpers/test-helper.ts @@ -2,7 +2,7 @@ declare const global: any; declare const Symbol: any; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; import {root} from '../../dist/cjs/util/root'; export function lowerCaseO(...args): Rx.Observable { diff --git a/spec/helpers/testScheduler-ui.ts b/spec/helpers/testScheduler-ui.ts index a37cad0356..cd16cd563a 100644 --- a/spec/helpers/testScheduler-ui.ts +++ b/spec/helpers/testScheduler-ui.ts @@ -7,7 +7,7 @@ import * as escapeRe from 'escape-string-regexp'; import * as chai from 'chai'; import * as sinonChai from 'sinon-chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; import * as marble from './marble-testing'; //setup sinon-chai diff --git a/spec/helpers/tests2png/diagram-test-runner.js b/spec/helpers/tests2png/diagram-test-runner.js index d62701eddd..ebfa3e2197 100644 --- a/spec/helpers/tests2png/diagram-test-runner.js +++ b/spec/helpers/tests2png/diagram-test-runner.js @@ -1,5 +1,5 @@ var root = require('../../../dist/cjs/util/root').root; -var Rx = require('../../../dist/cjs/Rx.KitchenSink'); +var Rx = require('../../../dist/cjs/Rx'); var painter = require('./painter'); function getInputStreams(rxTestScheduler) { diff --git a/spec/observables/IteratorObservable-spec.ts b/spec/observables/IteratorObservable-spec.ts index 0073334022..f25011a19b 100644 --- a/spec/observables/IteratorObservable-spec.ts +++ b/spec/observables/IteratorObservable-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; import {IteratorObservable} from '../../dist/cjs/observable/IteratorObservable'; declare const expectObservable; diff --git a/spec/observables/ScalarObservable-spec.ts b/spec/observables/ScalarObservable-spec.ts index 87a4d5010d..bf28dbb9f4 100644 --- a/spec/observables/ScalarObservable-spec.ts +++ b/spec/observables/ScalarObservable-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; import {ScalarObservable} from '../../dist/cjs/observable/ScalarObservable'; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/observables/SubscribeOnObservable-spec.ts b/spec/observables/SubscribeOnObservable-spec.ts index a13dc39427..fb313f0703 100644 --- a/spec/observables/SubscribeOnObservable-spec.ts +++ b/spec/observables/SubscribeOnObservable-spec.ts @@ -1,6 +1,6 @@ import {expect} from 'chai'; import * as sinon from 'sinon'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; import {SubscribeOnObservable} from '../../dist/cjs/observable/SubscribeOnObservable'; declare const {hot, expectObservable, expectSubscriptions}; diff --git a/spec/observables/bindCallback-spec.ts b/spec/observables/bindCallback-spec.ts index 859a11f3ed..23d0f567f8 100644 --- a/spec/observables/bindCallback-spec.ts +++ b/spec/observables/bindCallback-spec.ts @@ -1,6 +1,6 @@ import {expect} from 'chai'; import * as sinon from 'sinon'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const rxTestScheduler: Rx.TestScheduler; const Observable = Rx.Observable; diff --git a/spec/observables/bindNodeCallback-spec.ts b/spec/observables/bindNodeCallback-spec.ts index ce85639ae9..2aa3c67b6e 100644 --- a/spec/observables/bindNodeCallback-spec.ts +++ b/spec/observables/bindNodeCallback-spec.ts @@ -1,6 +1,6 @@ import {expect} from 'chai'; import * as sinon from 'sinon'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const rxTestScheduler: Rx.TestScheduler; const Observable = Rx.Observable; diff --git a/spec/observables/combineLatest-spec.ts b/spec/observables/combineLatest-spec.ts index 74742990e3..0c4aa570a0 100644 --- a/spec/observables/combineLatest-spec.ts +++ b/spec/observables/combineLatest-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, expectObservable, expectSubscriptions}; const Observable = Rx.Observable; diff --git a/spec/observables/concat-spec.ts b/spec/observables/concat-spec.ts index 2ff78f5997..3ac26a443d 100644 --- a/spec/observables/concat-spec.ts +++ b/spec/observables/concat-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, expectObservable, expectSubscriptions}; const Observable = Rx.Observable; diff --git a/spec/observables/dom/ajax-spec.ts b/spec/observables/dom/ajax-spec.ts index 8ec7575f14..5782b983ed 100644 --- a/spec/observables/dom/ajax-spec.ts +++ b/spec/observables/dom/ajax-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../../dist/cjs/Rx.DOM'; +import * as Rx from '../../../dist/cjs/Rx'; import {root} from '../../../dist/cjs/util/root'; import {MockXMLHttpRequest} from '../../helpers/ajax-helper'; diff --git a/spec/observables/dom/webSocket-spec.ts b/spec/observables/dom/webSocket-spec.ts index a415920c16..0d7aac3589 100644 --- a/spec/observables/dom/webSocket-spec.ts +++ b/spec/observables/dom/webSocket-spec.ts @@ -1,6 +1,6 @@ import {expect} from 'chai'; import * as sinon from 'sinon'; -import * as Rx from '../../../dist/cjs/Rx.DOM'; +import * as Rx from '../../../dist/cjs/Rx'; import {MockWebSocket} from '../../helpers/ajax-helper'; declare const __root__: any; diff --git a/spec/observables/forkJoin-spec.ts b/spec/observables/forkJoin-spec.ts index cbf1fedc8c..28ece00861 100644 --- a/spec/observables/forkJoin-spec.ts +++ b/spec/observables/forkJoin-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, expectObservable, expectSubscriptions}; import {lowerCaseO} from '../helpers/test-helper'; diff --git a/spec/observables/from-spec.ts b/spec/observables/from-spec.ts index 643d1079a0..b58a89792b 100644 --- a/spec/observables/from-spec.ts +++ b/spec/observables/from-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; import {$$iterator} from '../../dist/cjs/symbol/iterator'; declare const {asDiagram, expectObservable, Symbol, type}; diff --git a/spec/observables/fromEvent-spec.ts b/spec/observables/fromEvent-spec.ts index 00a94af829..ef8f0bd531 100644 --- a/spec/observables/fromEvent-spec.ts +++ b/spec/observables/fromEvent-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const rxTestScheduler: Rx.TestScheduler; declare const {hot, asDiagram, expectObservable, expectSubscriptions}; diff --git a/spec/observables/fromEventPattern-spec.ts b/spec/observables/fromEventPattern-spec.ts index 5760ccb96f..362774a2f5 100644 --- a/spec/observables/fromEventPattern-spec.ts +++ b/spec/observables/fromEventPattern-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const rxTestScheduler: Rx.TestScheduler; declare const {hot, asDiagram, expectObservable, expectSubscriptions}; diff --git a/spec/observables/generate-spec.ts b/spec/observables/generate-spec.ts index 52edaa8ae4..b30857fb8e 100644 --- a/spec/observables/generate-spec.ts +++ b/spec/observables/generate-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; import '../../dist/cjs/add/observable/generate'; import {TestScheduler} from '../../dist/cjs/testing/TestScheduler'; import {expect} from 'chai'; diff --git a/spec/observables/if-spec.ts b/spec/observables/if-spec.ts index 62135af9f0..4c1c3675ab 100644 --- a/spec/observables/if-spec.ts +++ b/spec/observables/if-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; const Observable = Rx.Observable; diff --git a/spec/observables/interval-spec.ts b/spec/observables/interval-spec.ts index 95ef15cd25..c9a6aa2f19 100644 --- a/spec/observables/interval-spec.ts +++ b/spec/observables/interval-spec.ts @@ -1,6 +1,6 @@ import {expect} from 'chai'; import * as sinon from 'sinon'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/observables/merge-spec.ts b/spec/observables/merge-spec.ts index 671cee1e0b..069ce2a1c6 100644 --- a/spec/observables/merge-spec.ts +++ b/spec/observables/merge-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/observables/of-spec.ts b/spec/observables/of-spec.ts index a32d1bf143..88223b0769 100644 --- a/spec/observables/of-spec.ts +++ b/spec/observables/of-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; import {ArrayObservable} from '../../dist/cjs/observable/ArrayObservable'; import {ScalarObservable} from '../../dist/cjs/observable/ScalarObservable'; import {EmptyObservable} from '../../dist/cjs/observable/EmptyObservable'; diff --git a/spec/observables/range-spec.ts b/spec/observables/range-spec.ts index cd299b6cb3..53d8fe4054 100644 --- a/spec/observables/range-spec.ts +++ b/spec/observables/range-spec.ts @@ -1,6 +1,6 @@ import {expect} from 'chai'; import * as sinon from 'sinon'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; import {RangeObservable} from '../../dist/cjs/observable/RangeObservable'; declare const {hot, asDiagram, expectObservable, expectSubscriptions}; diff --git a/spec/observables/throw-spec.ts b/spec/observables/throw-spec.ts index 4320ce3abf..a5c995969f 100644 --- a/spec/observables/throw-spec.ts +++ b/spec/observables/throw-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, asDiagram, expectObservable, expectSubscriptions}; import {ErrorObservable} from '../../dist/cjs/observable/ErrorObservable'; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/observables/timer-spec.ts b/spec/observables/timer-spec.ts index aa3af1b1db..4e444247e6 100644 --- a/spec/observables/timer-spec.ts +++ b/spec/observables/timer-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, asDiagram, time, expectObservable}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/observables/using-spec.ts b/spec/observables/using-spec.ts index 063e92c12f..b8e8755210 100644 --- a/spec/observables/using-spec.ts +++ b/spec/observables/using-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; const Observable = Rx.Observable; const Subscription = Rx.Subscription; diff --git a/spec/operators/auditTime-spec.ts b/spec/operators/auditTime-spec.ts index c5549cec1a..00a8cb83e2 100644 --- a/spec/operators/auditTime-spec.ts +++ b/spec/operators/auditTime-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/bufferTime-spec.ts b/spec/operators/bufferTime-spec.ts index feaa69c9f5..7ebcd7546c 100644 --- a/spec/operators/bufferTime-spec.ts +++ b/spec/operators/bufferTime-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, time, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/cache-spec.ts b/spec/operators/cache-spec.ts index bb1fa7307a..97ddb00608 100644 --- a/spec/operators/cache-spec.ts +++ b/spec/operators/cache-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, time, expectObservable}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/catch-spec.ts b/spec/operators/catch-spec.ts index 3e8a92dea2..1c2aeefc65 100644 --- a/spec/operators/catch-spec.ts +++ b/spec/operators/catch-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestSchdeuler: Rx.TestScheduler; diff --git a/spec/operators/concat-spec.ts b/spec/operators/concat-spec.ts index 0c1b8fdc0a..2a4bb92701 100644 --- a/spec/operators/concat-spec.ts +++ b/spec/operators/concat-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/concatAll-spec.ts b/spec/operators/concatAll-spec.ts index 53afecf30e..4d38220eba 100644 --- a/spec/operators/concatAll-spec.ts +++ b/spec/operators/concatAll-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/debounce-spec.ts b/spec/operators/debounce-spec.ts index 9a0e144d70..6c7c3e1951 100644 --- a/spec/operators/debounce-spec.ts +++ b/spec/operators/debounce-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/debounceTime-spec.ts b/spec/operators/debounceTime-spec.ts index 636421c54e..f18a534354 100644 --- a/spec/operators/debounceTime-spec.ts +++ b/spec/operators/debounceTime-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/delay-spec.ts b/spec/operators/delay-spec.ts index 1e7d81dd04..d67f884564 100644 --- a/spec/operators/delay-spec.ts +++ b/spec/operators/delay-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, asDiagram, cold, time, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/delayWhen-spec.ts b/spec/operators/delayWhen-spec.ts index 876cce87b0..6ff759e7a8 100644 --- a/spec/operators/delayWhen-spec.ts +++ b/spec/operators/delayWhen-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/distinctUntilKeyChanged-spec.ts b/spec/operators/distinctUntilKeyChanged-spec.ts index d5e13ffb4a..e2308472f6 100644 --- a/spec/operators/distinctUntilKeyChanged-spec.ts +++ b/spec/operators/distinctUntilKeyChanged-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; /** @test {distinctUntilKeyChanged} */ diff --git a/spec/operators/elementAt-spec.ts b/spec/operators/elementAt-spec.ts index 40c529a82f..62f026e222 100644 --- a/spec/operators/elementAt-spec.ts +++ b/spec/operators/elementAt-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; const Observable = Rx.Observable; diff --git a/spec/operators/exhaust-spec.ts b/spec/operators/exhaust-spec.ts index 534f7cdaf4..a2f8f7216f 100644 --- a/spec/operators/exhaust-spec.ts +++ b/spec/operators/exhaust-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; const Observable = Rx.Observable; diff --git a/spec/operators/exhaustMap-spec.ts b/spec/operators/exhaustMap-spec.ts index 407ea55115..1d5f1ad180 100644 --- a/spec/operators/exhaustMap-spec.ts +++ b/spec/operators/exhaustMap-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; const Observable = Rx.Observable; diff --git a/spec/operators/finally-spec.ts b/spec/operators/finally-spec.ts index 6ae9fd7463..6b16458c99 100644 --- a/spec/operators/finally-spec.ts +++ b/spec/operators/finally-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; const Observable = Rx.Observable; diff --git a/spec/operators/find-spec.ts b/spec/operators/find-spec.ts index d02c7799ca..e01e1eefa2 100644 --- a/spec/operators/find-spec.ts +++ b/spec/operators/find-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; const Observable = Rx.Observable; diff --git a/spec/operators/findIndex-spec.ts b/spec/operators/findIndex-spec.ts index 592a5ae60e..8c6b58df1d 100644 --- a/spec/operators/findIndex-spec.ts +++ b/spec/operators/findIndex-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; const Observable = Rx.Observable; diff --git a/spec/operators/groupBy-spec.ts b/spec/operators/groupBy-spec.ts index 23047e82dc..64081737c1 100644 --- a/spec/operators/groupBy-spec.ts +++ b/spec/operators/groupBy-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; import {GroupedObservable} from '../../dist/cjs/operator/groupBy'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; diff --git a/spec/operators/isEmpty-spec.ts b/spec/operators/isEmpty-spec.ts index 1de2d47c6a..5b88211372 100644 --- a/spec/operators/isEmpty-spec.ts +++ b/spec/operators/isEmpty-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; /** @test {isEmpty} */ diff --git a/spec/operators/max-spec.ts b/spec/operators/max-spec.ts index 3aa008ab1e..3e470435c7 100644 --- a/spec/operators/max-spec.ts +++ b/spec/operators/max-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; const Observable = Rx.Observable; diff --git a/spec/operators/merge-spec.ts b/spec/operators/merge-spec.ts index 25d0d030c4..36fe732eaf 100644 --- a/spec/operators/merge-spec.ts +++ b/spec/operators/merge-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/mergeScan-spec.ts b/spec/operators/mergeScan-spec.ts index 69fa39fdfd..c5a7d1c4a8 100644 --- a/spec/operators/mergeScan-spec.ts +++ b/spec/operators/mergeScan-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/observeOn-spec.ts b/spec/operators/observeOn-spec.ts index 4c88d41981..7ad8352656 100644 --- a/spec/operators/observeOn-spec.ts +++ b/spec/operators/observeOn-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/repeat-spec.ts b/spec/operators/repeat-spec.ts index e75540fd6b..da55583e60 100644 --- a/spec/operators/repeat-spec.ts +++ b/spec/operators/repeat-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/sampleTime-spec.ts b/spec/operators/sampleTime-spec.ts index c34ec896ea..6c5689f758 100644 --- a/spec/operators/sampleTime-spec.ts +++ b/spec/operators/sampleTime-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/startWith-spec.ts b/spec/operators/startWith-spec.ts index 50d95049cc..c7dc300fc9 100644 --- a/spec/operators/startWith-spec.ts +++ b/spec/operators/startWith-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/subscribeOn-spec.ts b/spec/operators/subscribeOn-spec.ts index 5189f0c56d..e668620a0e 100644 --- a/spec/operators/subscribeOn-spec.ts +++ b/spec/operators/subscribeOn-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/throttleTime-spec.ts b/spec/operators/throttleTime-spec.ts index 8d4a9f92c2..eb8316ba7c 100644 --- a/spec/operators/throttleTime-spec.ts +++ b/spec/operators/throttleTime-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/timeInterval-spec.ts b/spec/operators/timeInterval-spec.ts index 67430acec2..8b86e54544 100644 --- a/spec/operators/timeInterval-spec.ts +++ b/spec/operators/timeInterval-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/timeout-spec.ts b/spec/operators/timeout-spec.ts index 48edfc8dae..82b81d81df 100644 --- a/spec/operators/timeout-spec.ts +++ b/spec/operators/timeout-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/timeoutWith-spec.ts b/spec/operators/timeoutWith-spec.ts index 1bfed34294..fad796032f 100644 --- a/spec/operators/timeoutWith-spec.ts +++ b/spec/operators/timeoutWith-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/timestamp-spec.ts b/spec/operators/timestamp-spec.ts index ef8b26d71e..d3a071b961 100644 --- a/spec/operators/timestamp-spec.ts +++ b/spec/operators/timestamp-spec.ts @@ -1,4 +1,4 @@ -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/window-spec.ts b/spec/operators/window-spec.ts index 78aac89226..dfb27cbb55 100644 --- a/spec/operators/window-spec.ts +++ b/spec/operators/window-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, time, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/windowCount-spec.ts b/spec/operators/windowCount-spec.ts index e32786bee1..2c57db802b 100644 --- a/spec/operators/windowCount-spec.ts +++ b/spec/operators/windowCount-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, time, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/windowTime-spec.ts b/spec/operators/windowTime-spec.ts index 2fd9e67e84..d0f048aa6a 100644 --- a/spec/operators/windowTime-spec.ts +++ b/spec/operators/windowTime-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, time, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/windowToggle-spec.ts b/spec/operators/windowToggle-spec.ts index 85c62aaa1b..67e29c4d49 100644 --- a/spec/operators/windowToggle-spec.ts +++ b/spec/operators/windowToggle-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, time, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/operators/windowWhen-spec.ts b/spec/operators/windowWhen-spec.ts index 6a2f230b67..8956608c7d 100644 --- a/spec/operators/windowWhen-spec.ts +++ b/spec/operators/windowWhen-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, asDiagram, time, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/schedulers/AsapScheduler-spec.ts b/spec/schedulers/AsapScheduler-spec.ts index d1a03ebf34..45ecd405d9 100644 --- a/spec/schedulers/AsapScheduler-spec.ts +++ b/spec/schedulers/AsapScheduler-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; const asap = Rx.Scheduler.asap; diff --git a/spec/schedulers/TestScheduler-spec.ts b/spec/schedulers/TestScheduler-spec.ts index edfb08d8b1..79c83311b0 100644 --- a/spec/schedulers/TestScheduler-spec.ts +++ b/spec/schedulers/TestScheduler-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; declare const {hot, cold, time, expectObservable, expectSubscriptions}; declare const rxTestScheduler: Rx.TestScheduler; diff --git a/spec/schedulers/VirtualTimeScheduler-spec.ts b/spec/schedulers/VirtualTimeScheduler-spec.ts index 75545e8625..9c73ac84b1 100644 --- a/spec/schedulers/VirtualTimeScheduler-spec.ts +++ b/spec/schedulers/VirtualTimeScheduler-spec.ts @@ -1,5 +1,5 @@ import {expect} from 'chai'; -import * as Rx from '../../dist/cjs/Rx.KitchenSink'; +import * as Rx from '../../dist/cjs/Rx'; const VirtualTimeScheduler = Rx.VirtualTimeScheduler; diff --git a/src/Rx.DOM.ts b/src/Rx.DOM.ts deleted file mode 100644 index db684e1fb5..0000000000 --- a/src/Rx.DOM.ts +++ /dev/null @@ -1,25 +0,0 @@ -export * from './Rx'; - -import './add/observable/dom/ajax'; -import './add/observable/dom/webSocket'; - -export {AjaxRequest, AjaxResponse, AjaxError, AjaxTimeoutError} from './observable/dom/AjaxObservable'; - -// Rebuild `Scheduler` for Rx.DOM -import {asap} from './scheduler/asap'; -import {async} from './scheduler/async'; -import {queue} from './scheduler/queue'; -import {animationFrame} from './scheduler/animationFrame'; -/* tslint:disable:no-unused-variable */ -import {AsapScheduler} from './scheduler/AsapScheduler'; -import {AsyncScheduler} from './scheduler/AsyncScheduler'; -import {QueueScheduler} from './scheduler/QueueScheduler'; -import {AnimationFrameScheduler} from './scheduler/AnimationFrameScheduler'; -/* tslint:enable:no-unused-variable */ - -export var Scheduler = { - asap, - async, - queue, - animationFrame -}; \ No newline at end of file diff --git a/src/Rx.KitchenSink.ts b/src/Rx.KitchenSink.ts deleted file mode 100644 index 2583aca57a..0000000000 --- a/src/Rx.KitchenSink.ts +++ /dev/null @@ -1,28 +0,0 @@ - -export * from './Rx'; - -// statics -import './add/observable/if'; -import './add/observable/using'; - -// Operators -import './add/operator/distinct'; -import './add/operator/distinctKey'; -import './add/operator/distinctUntilKeyChanged'; -import './add/operator/elementAt'; -import './add/operator/exhaust'; -import './add/operator/exhaustMap'; -import './add/operator/find'; -import './add/operator/findIndex'; -import './add/operator/isEmpty'; -import './add/operator/max'; -import './add/operator/mergeScan'; -import './add/operator/min'; -import './add/operator/pairwise'; -import './add/operator/timeInterval'; -import './add/operator/timestamp'; - -export {TimeInterval} from './operator/timeInterval'; -export {Timestamp} from './operator/timestamp'; -export {TestScheduler} from './testing/TestScheduler'; -export {VirtualTimeScheduler} from './scheduler/VirtualTimeScheduler'; \ No newline at end of file diff --git a/src/Rx.ts b/src/Rx.ts index 1d1c8df6c1..7b7faab8c0 100644 --- a/src/Rx.ts +++ b/src/Rx.ts @@ -20,16 +20,22 @@ import './add/observable/fromEvent'; import './add/observable/fromEventPattern'; import './add/observable/fromPromise'; import './add/observable/generate'; +import './add/observable/if'; import './add/observable/interval'; import './add/observable/merge'; import './add/observable/race'; import './add/observable/never'; import './add/observable/of'; import './add/observable/range'; +import './add/observable/using'; import './add/observable/throw'; import './add/observable/timer'; import './add/observable/zip'; +//dom +import './add/observable/dom/ajax'; +import './add/observable/dom/webSocket'; + //operators import './add/operator/buffer'; import './add/operator/bufferCount'; @@ -51,14 +57,23 @@ import './add/operator/debounceTime'; import './add/operator/defaultIfEmpty'; import './add/operator/delay'; import './add/operator/delayWhen'; +import './add/operator/distinct'; +import './add/operator/distinctKey'; import './add/operator/distinctUntilChanged'; +import './add/operator/distinctUntilKeyChanged'; import './add/operator/do'; +import './add/operator/exhaust'; +import './add/operator/exhaustMap'; import './add/operator/expand'; +import './add/operator/elementAt'; import './add/operator/filter'; import './add/operator/finally'; +import './add/operator/find'; +import './add/operator/findIndex'; import './add/operator/first'; import './add/operator/groupBy'; import './add/operator/ignoreElements'; +import './add/operator/isEmpty'; import './add/operator/audit'; import './add/operator/auditTime'; import './add/operator/last'; @@ -67,12 +82,16 @@ import './add/operator/every'; import './add/operator/map'; import './add/operator/mapTo'; import './add/operator/materialize'; +import './add/operator/max'; import './add/operator/merge'; import './add/operator/mergeAll'; import './add/operator/mergeMap'; import './add/operator/mergeMapTo'; +import './add/operator/mergeScan'; +import './add/operator/min'; import './add/operator/multicast'; import './add/operator/observeOn'; +import './add/operator/pairwise'; import './add/operator/partition'; import './add/operator/pluck'; import './add/operator/publish'; @@ -103,8 +122,10 @@ import './add/operator/takeUntil'; import './add/operator/takeWhile'; import './add/operator/throttle'; import './add/operator/throttleTime'; +import './add/operator/timeInterval'; import './add/operator/timeout'; import './add/operator/timeoutWith'; +import './add/operator/timestamp'; import './add/operator/toArray'; import './add/operator/toPromise'; import './add/operator/window'; @@ -130,13 +151,20 @@ export {EmptyError} from './util/EmptyError'; export {ArgumentOutOfRangeError} from './util/ArgumentOutOfRangeError'; export {ObjectUnsubscribedError} from './util/ObjectUnsubscribedError'; export {UnsubscriptionError} from './util/UnsubscriptionError'; +export {TimeInterval} from './operator/timeInterval'; +export {Timestamp} from './operator/timestamp'; +export {TestScheduler} from './testing/TestScheduler'; +export {VirtualTimeScheduler} from './scheduler/VirtualTimeScheduler'; +export {AjaxRequest, AjaxResponse, AjaxError, AjaxTimeoutError} from './observable/dom/AjaxObservable'; import {asap} from './scheduler/asap'; import {async} from './scheduler/async'; import {queue} from './scheduler/queue'; +import {animationFrame} from './scheduler/animationFrame'; import {AsapScheduler} from './scheduler/AsapScheduler'; import {AsyncScheduler} from './scheduler/AsyncScheduler'; import {QueueScheduler} from './scheduler/QueueScheduler'; +import {AnimationFrameScheduler} from './scheduler/AnimationFrameScheduler'; import {$$rxSubscriber as rxSubscriber} from './symbol/rxSubscriber'; import {$$iterator as iterator} from './symbol/iterator'; import * as observable from 'symbol-observable'; @@ -157,7 +185,8 @@ import * as observable from 'symbol-observable'; let Scheduler = { asap, async, - queue + queue, + animationFrame }; /** diff --git a/tools/check-gzip-size.js b/tools/check-gzip-size.js index 49c69517fa..163fb37ba0 100644 --- a/tools/check-gzip-size.js +++ b/tools/check-gzip-size.js @@ -2,8 +2,7 @@ var gzipSize = require('gzip-size'); var fs = require('fs'); var path = require('path'); -var files = ['../dist/global/Rx.min.js', '../dist/global/Rx.KitchenSink.min.js']; - +var files = ['../dist/global/Rx.min.js']; files.map(getGzipSize).forEach(function (size, i) { console.log(path.basename(files[i]) + ': ' + formatSize(size) + ' gzipped'); diff --git a/tools/make-system-bundle.js b/tools/make-system-bundle.js index f122d1a643..2eb712a1f4 100644 --- a/tools/make-system-bundle.js +++ b/tools/make-system-bundle.js @@ -12,7 +12,6 @@ var config = { }; build('rxjs/Rx', '../dist/global/Rx.js', '../dist/global/Rx.min.js'); -build('rxjs/Rx.KitchenSink', '../dist/global/Rx.KitchenSink.js', '../dist/global/Rx.KitchenSink.min.js'); function build(name, inputFile, outputFile) { var devBuilder = new Builder(); diff --git a/tools/make-umd-bundle.js b/tools/make-umd-bundle.js index 2c5946ef05..75c032fd4d 100644 --- a/tools/make-umd-bundle.js +++ b/tools/make-umd-bundle.js @@ -6,10 +6,3 @@ var b = browserify('dist/cjs/Rx.js', { standalone: 'Rx' }); b.bundle().pipe(fs.createWriteStream('dist/global/Rx.umd.js')); - - -var b = browserify('dist/cjs/Rx.KitchenSink.js', { - baseDir: 'dist/cjs', - standalone: 'Rx.KitchenSink' -}); -b.bundle().pipe(fs.createWriteStream('dist/global/Rx.KitchenSink.umd.js')); diff --git a/tsconfig.json b/tsconfig.json index 21127bbdce..2ba8b1d0ab 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -14,8 +14,6 @@ "tabSize": 2 }, "files": [ - "src/Rx.ts", - "src/Rx.DOM.ts", - "src/Rx.KitchenSink.ts" + "src/Rx.ts" ] }