UNPKG

@reactivex/rxjs

Version:

Reactive Extensions for modern JavaScript

1,358 lines 2.49 MB
{ "type": "Program", "body": [ { "type": "ExpressionStatement", "expression": { "type": "Literal", "value": "use strict", "raw": "\"use strict\"", "range": [ 0, 12 ], "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 1, "column": 12 } } }, "range": [ 0, 13 ], "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 1, "column": 13 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "_this", "range": [ 18, 23 ], "loc": { "start": { "line": 2, "column": 4 }, "end": { "line": 2, "column": 9 } } }, "init": { "type": "ThisExpression", "range": [ 26, 30 ], "loc": { "start": { "line": 2, "column": 12 }, "end": { "line": 2, "column": 16 } } }, "range": [ 18, 30 ], "loc": { "start": { "line": 2, "column": 4 }, "end": { "line": 2, "column": 16 } } } ], "kind": "var", "range": [ 14, 31 ], "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 17 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "chai_1", "range": [ 36, 42 ], "loc": { "start": { "line": 3, "column": 4 }, "end": { "line": 3, "column": 10 } } }, "init": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "require", "range": [ 45, 52 ], "loc": { "start": { "line": 3, "column": 13 }, "end": { "line": 3, "column": 20 } } }, "arguments": [ { "type": "Literal", "value": "chai", "raw": "'chai'", "range": [ 53, 59 ], "loc": { "start": { "line": 3, "column": 21 }, "end": { "line": 3, "column": 27 } } } ], "range": [ 45, 60 ], "loc": { "start": { "line": 3, "column": 13 }, "end": { "line": 3, "column": 28 } } }, "range": [ 36, 60 ], "loc": { "start": { "line": 3, "column": 4 }, "end": { "line": 3, "column": 28 } } } ], "kind": "var", "range": [ 32, 61 ], "loc": { "start": { "line": 3, "column": 0 }, "end": { "line": 3, "column": 29 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "Rx", "range": [ 66, 68 ], "loc": { "start": { "line": 4, "column": 4 }, "end": { "line": 4, "column": 6 } } }, "init": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "require", "range": [ 71, 78 ], "loc": { "start": { "line": 4, "column": 9 }, "end": { "line": 4, "column": 16 } } }, "arguments": [ { "type": "Literal", "value": "../dist/cjs/Rx", "raw": "'../dist/cjs/Rx'", "range": [ 79, 95 ], "loc": { "start": { "line": 4, "column": 17 }, "end": { "line": 4, "column": 33 } } } ], "range": [ 71, 96 ], "loc": { "start": { "line": 4, "column": 9 }, "end": { "line": 4, "column": 34 } } }, "range": [ 66, 96 ], "loc": { "start": { "line": 4, "column": 4 }, "end": { "line": 4, "column": 34 } } } ], "kind": "var", "range": [ 62, 97 ], "loc": { "start": { "line": 4, "column": 0 }, "end": { "line": 4, "column": 35 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "Subject", "range": [ 102, 109 ], "loc": { "start": { "line": 5, "column": 4 }, "end": { "line": 5, "column": 11 } } }, "init": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "Rx", "range": [ 112, 114 ], "loc": { "start": { "line": 5, "column": 14 }, "end": { "line": 5, "column": 16 } } }, "property": { "type": "Identifier", "name": "Subject", "range": [ 115, 122 ], "loc": { "start": { "line": 5, "column": 17 }, "end": { "line": 5, "column": 24 } } }, "range": [ 112, 122 ], "loc": { "start": { "line": 5, "column": 14 }, "end": { "line": 5, "column": 24 } } }, "range": [ 102, 122 ], "loc": { "start": { "line": 5, "column": 4 }, "end": { "line": 5, "column": 24 } } } ], "kind": "var", "range": [ 98, 123 ], "loc": { "start": { "line": 5, "column": 0 }, "end": { "line": 5, "column": 25 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "Observable", "range": [ 128, 138 ], "loc": { "start": { "line": 6, "column": 4 }, "end": { "line": 6, "column": 14 } } }, "init": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "Rx", "range": [ 141, 143 ], "loc": { "start": { "line": 6, "column": 17 }, "end": { "line": 6, "column": 19 } } }, "property": { "type": "Identifier", "name": "Observable", "range": [ 144, 154 ], "loc": { "start": { "line": 6, "column": 20 }, "end": { "line": 6, "column": 30 } } }, "range": [ 141, 154 ], "loc": { "start": { "line": 6, "column": 17 }, "end": { "line": 6, "column": 30 } } }, "range": [ 128, 154 ], "loc": { "start": { "line": 6, "column": 4 }, "end": { "line": 6, "column": 30 } } } ], "kind": "var", "range": [ 124, 155 ], "loc": { "start": { "line": 6, "column": 0 }, "end": { "line": 6, "column": 31 } }, "trailingComments": [ { "type": "Block", "value": "* @test {Subject} ", "range": [ 156, 178 ], "loc": { "start": { "line": 7, "column": 0 }, "end": { "line": 7, "column": 22 } } } ] }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "describe", "range": [ 179, 187 ], "loc": { "start": { "line": 8, "column": 0 }, "end": { "line": 8, "column": 8 } } }, "arguments": [ { "type": "Literal", "value": "Subject", "raw": "'Subject'", "range": [ 188, 197 ], "loc": { "start": { "line": 8, "column": 9 }, "end": { "line": 8, "column": 18 } } }, { "type": "FunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "it", "range": [ 217, 219 ], "loc": { "start": { "line": 9, "column": 4 }, "end": { "line": 9, "column": 6 } } }, "arguments": [ { "type": "Literal", "value": "should pump values right on through itself", "raw": "'should pump values right on through itself'", "range": [ 220, 264 ], "loc": { "start": { "line": 9, "column": 7 }, "end": { "line": 9, "column": 51 } } }, { "type": "FunctionExpression", "id": null, "params": [ { "type": "Identifier", "name": "done", "range": [ 276, 280 ], "loc": { "start": { "line": 9, "column": 63 }, "end": { "line": 9, "column": 67 } } } ], "body": { "type": "BlockStatement", "body": [ { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "subject", "range": [ 296, 303 ], "loc": { "start": { "line": 10, "column": 12 }, "end": { "line": 10, "column": 19 } } }, "init": { "type": "NewExpression", "callee": { "type": "Identifier", "name": "Subject", "range": [ 310, 317 ], "loc": { "start": { "line": 10, "column": 26 }, "end": { "line": 10, "column": 33 } } }, "arguments": [], "range": [ 306, 319 ], "loc": { "start": { "line": 10, "column": 22 }, "end": { "line": 10, "column": 35 } } }, "range": [ 296, 319 ], "loc": { "start": { "line": 10, "column": 12 }, "end": { "line": 10, "column": 35 } } } ], "kind": "var", "range": [ 292, 320 ], "loc": { "start": { "line": 10, "column": 8 }, "end": { "line": 10, "column": 36 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "expected", "range": [ 333, 341 ], "loc": { "start": { "line": 11, "column": 12 }, "end": { "line": 11, "column": 20 } } }, "init": { "type": "ArrayExpression", "elements": [ { "type": "Literal", "value": "foo", "raw": "'foo'", "range": [ 345, 350 ], "loc": { "start": { "line": 11, "column": 24 }, "end": { "line": 11, "column": 29 } } }, { "type": "Literal", "value": "bar", "raw": "'bar'", "range": [ 352, 357 ], "loc": { "start": { "line": 11, "column": 31 }, "end": { "line": 11, "column": 36 } } } ], "range": [ 344, 358 ], "loc": { "start": { "line": 11, "column": 23 }, "end": { "line": 11, "column": 37 } } }, "range": [ 333, 358 ], "loc": { "start": { "line": 11, "column": 12 }, "end": { "line": 11, "column": 37 } } } ], "kind": "var", "range": [ 329, 359 ], "loc": { "start": { "line": 11, "column": 8 }, "end": { "line": 11, "column": 38 } } }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "subject", "range": [ 368, 375 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 15 } } }, "property": { "type": "Identifier", "name": "subscribe", "range": [ 376, 385 ], "loc": { "start": { "line": 12, "column": 16 }, "end": { "line": 12, "column": 25 } } }, "range": [ 368, 385 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 25 } } }, "arguments": [ { "type": "FunctionExpression", "id": null, "params": [ { "type": "Identifier", "name": "x", "range": [ 396, 397 ], "loc": { "start": { "line": 12, "column": 36 }, "end": { "line": 12, "column": 37 } } } ], "body": { "type": "BlockStatement", "body": [ { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "MemberExpression", "computed": false, "object": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "chai_1", "range": [ 413, 419 ], "loc": { "start": { "line": 13, "column": 12 }, "end": { "line": 13, "column": 18 } } }, "property": { "type": "Identifier", "name": "expect", "range": [ 420, 426 ], "loc": { "start": { "line": 13, "column": 19 }, "end": { "line": 13, "column": 25 } } }, "range": [ 413, 426 ], "loc": { "start": { "line": 13, "column": 12 }, "end": { "line": 13, "column": 25 } } }, "arguments": [ { "type": "Identifier", "name": "x", "range": [ 427, 428 ], "loc": { "start": { "line": 13, "column": 26 }, "end": { "line": 13, "column": 27 } } } ], "range": [ 413, 429 ], "loc": { "start": { "line": 13, "column": 12 }, "end": { "line": 13, "column": 28 } } }, "property": { "type": "Identifier", "name": "to", "range": [ 430, 432 ], "loc": { "start": { "line": 13, "column": 29 }, "end": { "line": 13, "column": 31 } } }, "range": [ 413, 432 ], "loc": { "start": { "line": 13, "column": 12 }, "end": { "line": 13, "column": 31 } } }, "property": { "type": "Identifier", "name": "equal", "range": [ 433, 438 ], "loc": { "start": { "line": 13, "column": 32 }, "end": { "line": 13, "column": 37 } } }, "range": [ 413, 438 ], "loc": { "start": { "line": 13, "column": 12 }, "end": { "line": 13, "column": 37 } } }, "arguments": [ { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "expected", "range": [ 439, 447 ], "loc": { "start": { "line": 13, "column": 38 }, "end": { "line": 13, "column": 46 } } }, "property": { "type": "Identifier", "name": "shift", "range": [ 448, 453 ], "loc": { "start": { "line": 13, "column": 47 }, "end": { "line": 13, "column": 52 } } }, "range": [ 439, 453 ], "loc": { "start": { "line": 13, "column": 38 }, "end": { "line": 13, "column": 52 } } }, "arguments": [], "range": [ 439, 455 ], "loc": { "start": { "line": 13, "column": 38 }, "end": { "line": 13, "column": 54 } } } ], "range": [ 413, 456 ], "loc": { "start": { "line": 13, "column": 12 }, "end": { "line": 13, "column": 55 } } }, "range": [ 413, 457 ], "loc": { "start": { "line": 13, "column": 12 }, "end": { "line": 13, "column": 56 } } } ], "range": [ 399, 467 ], "loc": { "start": { "line": 12, "column": 39 }, "end": { "line": 14, "column": 9 } } }, "generator": false, "expression": false, "range": [ 386, 467 ], "loc": { "start": { "line": 12, "column": 26 }, "end": { "line": 14, "column": 9 } } }, { "type": "Literal", "value": null, "raw": "null", "range": [ 469, 473 ], "loc": { "start": { "line": 14, "column": 11 }, "end": { "line": 14, "column": 15 } } }, { "type": "Identifier", "name": "done", "range": [ 475, 479 ], "loc": { "start": { "line": 14, "column": 17 }, "end": { "line": 14, "column": 21 } } } ], "range": [ 368, 480 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 14, "column": 22 } } }, "range": [ 368, 481 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 14, "column": 23 } } }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "subj