This repository was archived by the owner on Feb 26, 2024. It is now read-only.
File tree 3 files changed +12
-7
lines changed
3 files changed +12
-7
lines changed Original file line number Diff line number Diff line change 8
8
9
9
declare let define : any ;
10
10
( function ( root : any , factory : ( Rx : any ) => any ) {
11
- if ( typeof define === 'function' && define . amd ) {
12
- // AMD
13
- define ( [ 'Rx' ] , factory ) ;
14
- } else if ( typeof exports === 'object' ) {
11
+ if ( typeof exports === 'object' && typeof module !== 'undefined' ) {
15
12
// Node, CommonJS-like
16
13
module . exports = factory ( require ( 'rxjs' ) ) ;
14
+ } else if ( typeof define === 'function' && define . amd ) {
15
+ // AMD
16
+ define ( [ 'rxjs' ] , factory ) ;
17
17
} else {
18
- root . returnExports = factory ( root . Rx ) ;
18
+ factory ( root . Rx ) ;
19
19
}
20
20
} ( typeof window !== 'undefined' && window || typeof self !== 'undefined' && self || global ,
21
21
( Rx : any ) => {
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ declare const __karma__: {
15
15
__karma__ . loaded = function ( ) { } ;
16
16
( window as any ) . global = window ;
17
17
18
- System . config ( { defaultJSExtensions : true , map : { 'Rx ' : 'base/node_modules/rxjs/bundles/Rx.js' } } ) ;
18
+ System . config ( { defaultJSExtensions : true , map : { 'rxjs ' : 'base/node_modules/rxjs/bundles/Rx.js' } } ) ;
19
19
let browserPatchedPromise : any = null ;
20
20
if ( ( window as any ) [ ( Zone as any ) . __symbol__ ( 'setTimeout' ) ] ) {
21
21
browserPatchedPromise = Promise . resolve ( 'browserPatched' ) ;
Original file line number Diff line number Diff line change 6
6
* found in the LICENSE file at https://angular.io/license
7
7
*/
8
8
9
- const rxjs = require ( 'Rx' ) ;
9
+ let rxjs ;
10
+ if ( typeof exports === 'object' ) {
11
+ rxjs = require ( 'rxjs' ) ;
12
+ } else {
13
+ rxjs = ( window as any ) . Rx ;
14
+ }
10
15
const Observable = rxjs . Observable ;
11
16
const Subscriber = rxjs . Subscriber ;
12
17
You can’t perform that action at this time.
0 commit comments