UNPKG

@reactivex/rxjs

Version:

Reactive Extensions for modern JavaScript

1,302 lines 191 kB
{ "type": "Program", "body": [ { "type": "ImportDeclaration", "specifiers": [ { "type": "ImportSpecifier", "local": { "type": "Identifier", "name": "AsyncAction", "range": [ 9, 20 ], "loc": { "start": { "line": 1, "column": 9 }, "end": { "line": 1, "column": 20 } } }, "imported": { "type": "Identifier", "name": "AsyncAction", "range": [ 9, 20 ], "loc": { "start": { "line": 1, "column": 9 }, "end": { "line": 1, "column": 20 } } }, "range": [ 9, 20 ], "loc": { "start": { "line": 1, "column": 9 }, "end": { "line": 1, "column": 20 } } } ], "source": { "type": "Literal", "value": "./AsyncAction", "raw": "'./AsyncAction'", "range": [ 28, 43 ], "loc": { "start": { "line": 1, "column": 28 }, "end": { "line": 1, "column": 43 } } }, "range": [ 0, 44 ], "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 1, "column": 44 } } }, { "type": "ImportDeclaration", "specifiers": [ { "type": "ImportSpecifier", "local": { "type": "Identifier", "name": "AnimationFrame", "range": [ 54, 68 ], "loc": { "start": { "line": 2, "column": 9 }, "end": { "line": 2, "column": 23 } } }, "imported": { "type": "Identifier", "name": "AnimationFrame", "range": [ 54, 68 ], "loc": { "start": { "line": 2, "column": 9 }, "end": { "line": 2, "column": 23 } } }, "range": [ 54, 68 ], "loc": { "start": { "line": 2, "column": 9 }, "end": { "line": 2, "column": 23 } } } ], "source": { "type": "Literal", "value": "../util/AnimationFrame", "raw": "'../util/AnimationFrame'", "range": [ 76, 100 ], "loc": { "start": { "line": 2, "column": 31 }, "end": { "line": 2, "column": 55 } } }, "range": [ 45, 101 ], "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 56 } }, "trailingComments": [ { "type": "Block", "value": "*\n * We need this JSDoc comment for affecting ESDoc.\n * @ignore\n * @extends {Ignored}\n ", "range": [ 102, 193 ], "loc": { "start": { "line": 3, "column": 0 }, "end": { "line": 7, "column": 3 } } } ] }, { "type": "ExportNamedDeclaration", "declaration": { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "AnimationFrameAction", "range": [ 205, 225 ], "loc": { "start": { "line": 8, "column": 11 }, "end": { "line": 8, "column": 31 } } }, "init": { "type": "CallExpression", "callee": { "type": "FunctionExpression", "id": null, "params": [ { "type": "Identifier", "name": "_super", "range": [ 239, 245 ], "loc": { "start": { "line": 8, "column": 45 }, "end": { "line": 8, "column": 51 } } } ], "body": { "type": "BlockStatement", "body": [ { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "__extends", "range": [ 253, 262 ], "loc": { "start": { "line": 9, "column": 4 }, "end": { "line": 9, "column": 13 } } }, "arguments": [ { "type": "Identifier", "name": "AnimationFrameAction", "range": [ 263, 283 ], "loc": { "start": { "line": 9, "column": 14 }, "end": { "line": 9, "column": 34 } } }, { "type": "Identifier", "name": "_super", "range": [ 285, 291 ], "loc": { "start": { "line": 9, "column": 36 }, "end": { "line": 9, "column": 42 } } } ], "range": [ 253, 292 ], "loc": { "start": { "line": 9, "column": 4 }, "end": { "line": 9, "column": 43 } } }, "range": [ 253, 293 ], "loc": { "start": { "line": 9, "column": 4 }, "end": { "line": 9, "column": 44 } } }, { "type": "FunctionDeclaration", "id": { "type": "Identifier", "name": "AnimationFrameAction", "range": [ 307, 327 ], "loc": { "start": { "line": 10, "column": 13 }, "end": { "line": 10, "column": 33 } } }, "params": [ { "type": "Identifier", "name": "scheduler", "range": [ 328, 337 ], "loc": { "start": { "line": 10, "column": 34 }, "end": { "line": 10, "column": 43 } } }, { "type": "Identifier", "name": "work", "range": [ 339, 343 ], "loc": { "start": { "line": 10, "column": 45 }, "end": { "line": 10, "column": 49 } } } ], "body": { "type": "BlockStatement", "body": [ { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "_super", "range": [ 355, 361 ], "loc": { "start": { "line": 11, "column": 8 }, "end": { "line": 11, "column": 14 } } }, "property": { "type": "Identifier", "name": "call", "range": [ 362, 366 ], "loc": { "start": { "line": 11, "column": 15 }, "end": { "line": 11, "column": 19 } } }, "range": [ 355, 366 ], "loc": { "start": { "line": 11, "column": 8 }, "end": { "line": 11, "column": 19 } } }, "arguments": [ { "type": "ThisExpression", "range": [ 367, 371 ], "loc": { "start": { "line": 11, "column": 20 }, "end": { "line": 11, "column": 24 } } }, { "type": "Identifier", "name": "scheduler", "range": [ 373, 382 ], "loc": { "start": { "line": 11, "column": 26 }, "end": { "line": 11, "column": 35 } } }, { "type": "Identifier", "name": "work", "range": [ 384, 388 ], "loc": { "start": { "line": 11, "column": 37 }, "end": { "line": 11, "column": 41 } } } ], "range": [ 355, 389 ], "loc": { "start": { "line": 11, "column": 8 }, "end": { "line": 11, "column": 42 } } }, "range": [ 355, 390 ], "loc": { "start": { "line": 11, "column": 8 }, "end": { "line": 11, "column": 43 } } }, { "type": "ExpressionStatement", "expression": { "type": "AssignmentExpression", "operator": "=", "left": { "type": "MemberExpression", "computed": false, "object": { "type": "ThisExpression", "range": [ 399, 403 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 12 } } }, "property": { "type": "Identifier", "name": "scheduler", "range": [ 404, 413 ], "loc": { "start": { "line": 12, "column": 13 }, "end": { "line": 12, "column": 22 } } }, "range": [ 399, 413 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 22 } } }, "right": { "type": "Identifier", "name": "scheduler", "range": [ 416, 425 ], "loc": { "start": { "line": 12, "column": 25 }, "end": { "line": 12, "column": 34 } } }, "range": [ 399, 425 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 34 } } }, "range": [ 399, 426 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 35 } } }, { "type": "ExpressionStatement", "expression": { "type": "AssignmentExpression", "operator": "=", "left": { "type": "MemberExpression", "computed": false, "object": { "type": "ThisExpression", "range": [ 435, 439 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 12 } } }, "property": { "type": "Identifier", "name": "work", "range": [ 440, 444 ], "loc": { "start": { "line": 13, "column": 13 }, "end": { "line": 13, "column": 17 } } }, "range": [ 435, 444 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 17 } } }, "right": { "type": "Identifier", "name": "work", "range": [ 447, 451 ], "loc": { "start": { "line": 13, "column": 20 }, "end": { "line": 13, "column": 24 } } }, "range": [ 435, 451 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 24 } } }, "range": [ 435, 452 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 25 } } } ], "range": [ 345, 458 ], "loc": { "start": { "line": 10, "column": 51 }, "end": { "line": 14, "column": 5 } } }, "generator": false, "expression": false, "range": [ 298, 458 ], "loc": { "start": { "line": 10, "column": 4 }, "end": { "line": 14, "column": 5 } } }, { "type": "ExpressionStatement", "expression": { "type": "AssignmentExpression", "operator": "=", "left": { "type": "MemberExpression", "computed": false, "object": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "AnimationFrameAction", "range": [ 463, 483 ], "loc": { "start": { "line": 15, "column": 4 }, "end": { "line": 15, "column": 24 } } }, "property": { "type": "Identifier", "name": "prototype", "range": [ 484, 493 ], "loc": { "start": { "line": 15, "column": 25 }, "end": { "line": 15, "column": 34 } } }, "range": [ 463, 493 ], "loc": { "start": { "line": 15, "column": 4 }, "end": { "line": 15, "column": 34 } } }, "property": { "type": "Identifier", "name": "requestAsyncId", "range": [ 494, 508 ], "loc": { "start": { "line": 15, "column": 35 }, "end": { "line": 15, "column": 49 } } }, "range": [ 463, 508 ], "loc": { "start": { "line": 15, "column": 4 }, "end": { "line": 15, "column": 49 } } }, "right": { "type": "FunctionExpression", "id": null, "params": [ { "type": "Identifier", "name": "scheduler", "range": [ 521, 530 ], "loc": { "start": { "line": 15, "column": 62 }, "end": { "line": 15, "column": 71 } } }, { "type": "Identifier", "name": "id", "range": [ 532, 534 ], "loc": { "start": { "line": 15, "column": 73 }, "end": { "line": 15, "column": 75 } } }, { "type": "Identifier", "name": "delay", "range": [ 536, 541 ], "loc": { "start": { "line": 15, "column": 77 }, "end": { "line": 15, "column": 82 } } } ], "body": { "type": "BlockStatement", "body": [ { "type": "IfStatement", "test": { "type": "BinaryExpression", "operator": "===", "left": { "type": "Identifier", "name": "delay", "range": [ 557, 562 ], "loc": { "start": { "line": 16, "column": 12 }, "end": { "line": 16, "column": 17 } } }, "right": { "type": "UnaryExpression", "operator": "void", "argument": { "type": "Literal", "value": 0, "raw": "0", "range": [ 572, 573 ], "loc": { "start": { "line": 16, "column": 27 }, "end": { "line": 16, "column": 28 } } }, "prefix": true, "range": [ 567, 573 ], "loc": { "start": { "line": 16, "column": 22 }, "end": { "line": 16, "column": 28 } } }, "range": [ 557, 573 ], "loc": { "start": { "line": 16, "column": 12 }, "end": { "line": 16, "column": 28 } } }, "consequent": { "type": "BlockStatement", "body": [ { "type": "ExpressionStatement", "expression": { "type": "AssignmentExpression", "operator": "=", "left": { "type": "Identifier", "name": "delay", "range": [ 577, 582 ], "loc": { "start": { "line": 16, "column": 32 }, "end": { "line": 16, "column": 37 } } }, "right": { "type": "Literal", "value": 0, "raw": "0", "range": [ 585, 586 ], "loc": { "start": { "line": 16, "column": 40 }, "end": { "line": 16, "column": 41 } } }, "range": [ 577, 586 ], "loc": { "start": { "line": 16, "column": 32 }, "end": { "line": 16, "column": 41 } } }, "range": [ 577, 587 ], "loc": { "start": { "line": 16, "column": 32 }, "end": { "line": 16, "column": 42 } } } ], "range": [ 575, 589 ], "loc": { "start": { "line": 16, "column": 30 }, "end": { "line": 16, "column": 44 } } }, "alternate": null, "range": [ 553, 589 ], "loc": { "start": { "line": 16, "column": 8 }, "end": { "line": 16, "column": 44 } }, "trailingComments": [ { "type": "Line", "value": " If delay is greater than 0, request as an async action.", "range": [ 598, 656 ], "loc": { "start": { "line": 17, "column": 8 }, "end": { "line": 17, "column": 66 } } } ] }, { "type": "IfStatement", "test": { "type": "LogicalExpression", "operator": "&&", "left": { "type": "BinaryExpression", "operator": "!==", "left": { "type": "Identifier", "name": "delay", "range": [ 669, 674 ], "loc": { "start": { "line": 18, "column": 12 }, "end": { "line": 18, "column": 17 } } }, "right": { "type": "Literal", "value": null, "raw": "null", "range": [ 679, 683 ], "loc": { "start": { "line": 18, "column": 22 }, "end": { "line": 18, "column": 26 } } }, "range": [ 669, 683 ], "loc": { "start": { "line": 18, "column": 12 }, "end": { "line": 18, "column": 26 } } }, "right": { "type": "BinaryExpression", "operator": ">", "left": { "type": "Identifier", "name": "delay", "range": [ 687, 692 ], "loc": { "start": { "line": 18, "column": 30 }, "end": { "line": 18, "column": 35 } } }, "right": { "type": "Literal", "value": 0, "raw": "0", "range": [ 695, 696 ], "loc": { "start": { "line": 18, "column": 38 }, "end": { "line": 18, "column": 39 } } }, "range": [ 687, 696 ], "loc": { "start": { "line": 18, "column": 30 }, "end": { "line": 18, "column": 39 } } }, "range": [ 669, 696 ], "loc": { "start": { "line": 18, "column": 12 }, "end": { "line": 18, "column": 39 } } }, "consequent": { "type": "BlockStatement", "body": [ { "type": "ReturnStatement", "argument": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "MemberExpression", "computed": false, "object": { "type": "MemberExpressio