From 077ebf63c51bb6e30ede37b647b90a959bab9bab Mon Sep 17 00:00:00 2001 From: Paul Gschwendtner Date: Sun, 9 Jul 2017 08:20:34 +0200 Subject: [PATCH] build: fix rollup globals for examples package (#5611) Recently the rollup globals have been changed because the operators are no longer applied to the prototype (using `/add/` imports). This now causes some warnigns and invalid id's in the bundles of the Material examples because those still use the `/add/` imports in some examples. --- tools/package-tools/rollup-helpers.ts | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/tools/package-tools/rollup-helpers.ts b/tools/package-tools/rollup-helpers.ts index 2aa8d794421..5068ce0795d 100644 --- a/tools/package-tools/rollup-helpers.ts +++ b/tools/package-tools/rollup-helpers.ts @@ -24,7 +24,7 @@ const ROLLUP_GLOBALS = { '@angular/material': 'ng.material', '@angular/cdk': 'ng.cdk', - // Rxjs dependencies + // RxJS dependencies 'rxjs/BehaviorSubject': 'Rx', 'rxjs/Observable': 'Rx', 'rxjs/Subject': 'Rx', @@ -49,6 +49,14 @@ const ROLLUP_GLOBALS = { 'rxjs/operator/switchMap': 'Rx.Observable.prototype', 'rxjs/operator/takeUntil': 'Rx.Observable.prototype', 'rxjs/operator/toPromise': 'Rx.Observable.prototype', + + // RxJS imports for the examples package + 'rxjs/add/observable/merge': 'Rx.Observable', + 'rxjs/add/observable/fromEvent': 'Rx.Observable', + 'rxjs/add/operator/startWith': 'Rx.Observable.prototype', + 'rxjs/add/operator/map': 'Rx.Observable.prototype', + 'rxjs/add/operator/debounceTime': 'Rx.Observable.prototype', + 'rxjs/add/operator/distinctUntilChanged': 'Rx.Observable.prototype', }; export type BundleConfig = {