├── .gitignore ├── LICENSE ├── README.md ├── angular2-app ├── LICENSE ├── README.md ├── app │ ├── app.component.ts │ ├── app.module.ts │ ├── main.ts │ └── transpiled-js │ │ ├── app.component.js │ │ ├── app.component.js.map │ │ ├── app.module.js │ │ ├── app.module.js.map │ │ ├── main.js │ │ └── main.js.map ├── index.html ├── package.json ├── style.css ├── systemjs.config.js ├── tsconfig.json ├── typings.json └── typings │ ├── globals │ ├── core-js │ │ ├── index.d.ts │ │ └── typings.json │ ├── jasmine │ │ ├── index.d.ts │ │ └── typings.json │ └── node │ │ ├── index.d.ts │ │ └── typings.json │ └── index.d.ts ├── app.js └── package.json /.gitignore: -------------------------------------------------------------------------------- 1 | # Logs 2 | logs 3 | *.log 4 | npm-debug.log* 5 | 6 | # Runtime data 7 | pids 8 | *.pid 9 | *.seed 10 | 11 | # Directory for instrumented libs generated by jscoverage/JSCover 12 | lib-cov 13 | 14 | # Coverage directory used by tools like istanbul 15 | coverage 16 | 17 | # nyc test coverage 18 | .nyc_output 19 | 20 | # Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) 21 | .grunt 22 | 23 | # node-waf configuration 24 | .lock-wscript 25 | 26 | # Compiled binary addons (http://nodejs.org/api/addons.html) 27 | build/Release 28 | 29 | # Dependency directories 30 | angular2-app/node_modules 31 | node_modules 32 | jspm_packages 33 | 34 | # Optional npm cache directory 35 | .npm 36 | 37 | # Optional REPL history 38 | .node_repl_history 39 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2017 Rahil Shaikh 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # fileupload-nodejs-gridfs-angular2 2 | File Upload application with Nodejs, GridFS and Angular 2 3 | 4 | ## Quick Setup 5 | - `git clone https://github.com/rahil471/fileupload-nodejs-gridfs-angular2.git` 6 | - Naviagte into the directory 7 | - `npm install` 8 | - MongoDB should be installed and running on default port 9 | - `node app.js` this will start the node server on port 3002 10 | - `cd angular2-app` 11 | - `npm install` 12 | - `npm start` 13 | - `angular2 app will be running on port 3000` 14 | -------------------------------------------------------------------------------- /angular2-app/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2016 Rahil Shaikh 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /angular2-app/README.md: -------------------------------------------------------------------------------- 1 | # angular2-fast-start 2 | A repo to get you up and running with Angular 2 3 | -------------------------------------------------------------------------------- /angular2-app/app/app.component.ts: -------------------------------------------------------------------------------- 1 | import { Component } from '@angular/core'; 2 | import { FileUploader } from 'ng2-file-upload'; 3 | 4 | @Component({ 5 | selector: 'my-app', 6 | template: ` 17 |
18 |
19 |
20 |
21 |
22 | 23 | 24 |
25 |
26 | 27 | 28 |
29 |
30 |
31 |
32 |

File Upload with Angular 2 and Node

33 | Queue length: {{ uploader?.queue?.length }} 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 54 | 59 | 73 | 74 | 75 |
NameSizeProgressStatusActions
{{ item.file.name }}{{ item.file.size/1024/1024 | number:'.2' }} MB 50 |
51 |
52 |
53 |
55 | 56 | 57 | 58 | 60 | 64 | 68 | 72 |
76 | 77 |
78 |
79 | Queue progress: 80 |
81 |
82 |
83 |
84 | 88 | 92 | 96 |
97 |
98 |
99 |
` 100 | }) 101 | export class AppComponent { 102 | public uploader:FileUploader = new FileUploader({url:'http://localhost:3002/upload'}); 103 | } -------------------------------------------------------------------------------- /angular2-app/app/app.module.ts: -------------------------------------------------------------------------------- 1 | import { NgModule } from '@angular/core'; 2 | import { BrowserModule } from '@angular/platform-browser'; 3 | import { FileSelectDirective, FileDropDirective } from 'ng2-file-upload'; 4 | 5 | import { AppComponent } from './app.component'; 6 | 7 | @NgModule({ 8 | imports: [BrowserModule], 9 | exports: [], 10 | declarations: [AppComponent, FileSelectDirective], /** The FileSelectDirective is what we will require*/ 11 | providers: [], 12 | bootstrap: [AppComponent] 13 | }) 14 | export class AppModule { } -------------------------------------------------------------------------------- /angular2-app/app/main.ts: -------------------------------------------------------------------------------- 1 | import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'; 2 | import { AppModule } from './app.module'; 3 | const platform = platformBrowserDynamic(); 4 | platform.bootstrapModule(AppModule); 5 | -------------------------------------------------------------------------------- /angular2-app/app/transpiled-js/app.component.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) { 3 | var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; 4 | if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc); 5 | else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; 6 | return c > 3 && r && Object.defineProperty(target, key, r), r; 7 | }; 8 | Object.defineProperty(exports, "__esModule", { value: true }); 9 | var core_1 = require("@angular/core"); 10 | var ng2_file_upload_1 = require("ng2-file-upload"); 11 | var AppComponent = (function () { 12 | function AppComponent() { 13 | this.uploader = new ng2_file_upload_1.FileUploader({ url: 'http://localhost:3002/upload' }); 14 | } 15 | return AppComponent; 16 | }()); 17 | AppComponent = __decorate([ 18 | core_1.Component({ 19 | selector: 'my-app', 20 | template: "\n
\n
\n
\n
\n
\n \n \n
\n
\n \n \n
\n
\n
\n
\n

File Upload with Angular 2 and Node

\n Queue length: {{ uploader?.queue?.length }}\n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
NameSizeProgressStatusActions
{{ item.file.name }}{{ item.file.size/1024/1024 | number:'.2' }} MB\n
\n
\n
\n
\n \n \n \n \n \n \n \n
\n\n
\n
\n Queue progress:\n
\n
\n
\n
\n \n \n \n
\n
\n
\n
" 21 | }) 22 | ], AppComponent); 23 | exports.AppComponent = AppComponent; 24 | //# sourceMappingURL=app.component.js.map -------------------------------------------------------------------------------- /angular2-app/app/transpiled-js/app.component.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"app.component.js","sourceRoot":"","sources":["../app.component.ts"],"names":[],"mappings":";;;;;;;;AAAA,sCAA0C;AAC1C,mDAA+C;AAmG/C,IAAa,YAAY;IAjGzB;QAkGW,aAAQ,GAAgB,IAAI,8BAAY,CAAC,EAAC,GAAG,EAAC,8BAA8B,EAAC,CAAC,CAAC;IAC1F,CAAC;IAAD,mBAAC;AAAD,CAAC,AAFD,IAEC;AAFY,YAAY;IAjGxB,gBAAS,CAAC;QACP,QAAQ,EAAE,QAAQ;QAClB,QAAQ,EAAE,wiMA6FS;KACtB,CAAC;GACW,YAAY,CAExB;AAFY,oCAAY"} -------------------------------------------------------------------------------- /angular2-app/app/transpiled-js/app.module.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) { 3 | var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; 4 | if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc); 5 | else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; 6 | return c > 3 && r && Object.defineProperty(target, key, r), r; 7 | }; 8 | Object.defineProperty(exports, "__esModule", { value: true }); 9 | var core_1 = require("@angular/core"); 10 | var platform_browser_1 = require("@angular/platform-browser"); 11 | var ng2_file_upload_1 = require("ng2-file-upload"); 12 | var app_component_1 = require("./app.component"); 13 | var AppModule = (function () { 14 | function AppModule() { 15 | } 16 | return AppModule; 17 | }()); 18 | AppModule = __decorate([ 19 | core_1.NgModule({ 20 | imports: [platform_browser_1.BrowserModule], 21 | exports: [], 22 | declarations: [app_component_1.AppComponent, ng2_file_upload_1.FileSelectDirective], 23 | providers: [], 24 | bootstrap: [app_component_1.AppComponent] 25 | }) 26 | ], AppModule); 27 | exports.AppModule = AppModule; 28 | //# sourceMappingURL=app.module.js.map -------------------------------------------------------------------------------- /angular2-app/app/transpiled-js/app.module.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"app.module.js","sourceRoot":"","sources":["../app.module.ts"],"names":[],"mappings":";;;;;;;;AAAA,sCAAyC;AACzC,8DAA0D;AAC1D,mDAAyE;AAEzE,iDAAiD;AASjD,IAAa,SAAS;IAAtB;IAAyB,CAAC;IAAD,gBAAC;AAAD,CAAC,AAA1B,IAA0B;AAAb,SAAS;IAPrB,eAAQ,CAAC;QACN,OAAO,EAAE,CAAC,gCAAa,CAAC;QACxB,OAAO,EAAE,EAAE;QACX,YAAY,EAAE,CAAC,4BAAY,EAAE,qCAAmB,CAAC;QACjD,SAAS,EAAE,EAAE;QACb,SAAS,EAAE,CAAC,4BAAY,CAAC;KAC5B,CAAC;GACW,SAAS,CAAI;AAAb,8BAAS"} -------------------------------------------------------------------------------- /angular2-app/app/transpiled-js/main.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | var platform_browser_dynamic_1 = require("@angular/platform-browser-dynamic"); 4 | var app_module_1 = require("./app.module"); 5 | var platform = platform_browser_dynamic_1.platformBrowserDynamic(); 6 | platform.bootstrapModule(app_module_1.AppModule); 7 | //# sourceMappingURL=main.js.map -------------------------------------------------------------------------------- /angular2-app/app/transpiled-js/main.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"main.js","sourceRoot":"","sources":["../main.ts"],"names":[],"mappings":";;AAAA,8EAA2E;AAC3E,2CAAyC;AACzC,IAAM,QAAQ,GAAG,iDAAsB,EAAE,CAAC;AAC1C,QAAQ,CAAC,eAAe,CAAC,sBAAS,CAAC,CAAC"} -------------------------------------------------------------------------------- /angular2-app/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /angular2-app/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "angular2-start", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "start": "tsc && concurrently \"npm run tsc:w\" \"npm run lite\" ", 8 | "lite": "lite-server", 9 | "postinstall": "typings install", 10 | "tsc": "tsc", 11 | "tsc:w": "tsc -w", 12 | "typings": "typings" 13 | }, 14 | "keywords": [], 15 | "author": "", 16 | "license": "MIT", 17 | "dependencies": { 18 | "@angular/common": "~2.4.1", 19 | "@angular/compiler": "~2.4.1", 20 | "@angular/core": "~2.4.1", 21 | "@angular/forms": "~2.4.1", 22 | "@angular/http": "~2.4.1", 23 | "@angular/platform-browser": "~2.4.1", 24 | "@angular/platform-browser-dynamic": "~2.4.1", 25 | "@angular/router": "~3.1.0", 26 | "@angular/upgrade": "~2.4.1", 27 | "angular-in-memory-web-api": "~0.1.5", 28 | "bootstrap": "^3.3.7", 29 | "core-js": "^2.4.1", 30 | "ng2-file-upload": "^1.1.2", 31 | "reflect-metadata": "^0.1.8", 32 | "rxjs": "5.0.0-beta.12", 33 | "systemjs": "0.19.39", 34 | "zone.js": "^0.6.25" 35 | }, 36 | "devDependencies": { 37 | "concurrently": "^3.1.0", 38 | "live-server": "^1.1.0", 39 | "typescript": "^2.0.3", 40 | "typings": "^1.4.0" 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /angular2-app/style.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rahil471/fileupload-nodejs-gridfs-angular2/9150bec8ce5c50603388d61493cf186eb817c12f/angular2-app/style.css -------------------------------------------------------------------------------- /angular2-app/systemjs.config.js: -------------------------------------------------------------------------------- 1 | /** 2 | * System configuration for Angular samples 3 | * Adjust as necessary for your application needs. 4 | */ 5 | (function (global) { 6 | System.config({ 7 | paths: { 8 | // paths serve as alias 9 | 'npm:': 'node_modules/' 10 | }, 11 | // map tells the System loader where to look for things 12 | map: { 13 | // our app is within the app folder 14 | app: 'app', 15 | // angular bundles 16 | '@angular/core': 'npm:@angular/core/bundles/core.umd.js', 17 | '@angular/common': 'npm:@angular/common/bundles/common.umd.js', 18 | '@angular/compiler': 'npm:@angular/compiler/bundles/compiler.umd.js', 19 | '@angular/platform-browser': 'npm:@angular/platform-browser/bundles/platform-browser.umd.js', 20 | '@angular/platform-browser-dynamic': 'npm:@angular/platform-browser-dynamic/bundles/platform-browser-dynamic.umd.js', 21 | '@angular/http': 'npm:@angular/http/bundles/http.umd.js', 22 | '@angular/router': 'npm:@angular/router/bundles/router.umd.js', 23 | '@angular/forms': 'npm:@angular/forms/bundles/forms.umd.js', 24 | // other libraries 25 | 'rxjs': 'npm:rxjs', 26 | 'angular-in-memory-web-api': 'npm:angular-in-memory-web-api', 27 | /** Path for ng2-file-upload */ 28 | 'ng2-file-upload' : 'npm:ng2-file-upload' 29 | /** Path for ng2-file-upload */ 30 | }, 31 | // packages tells the System loader how to load when no filename and/or no extension 32 | packages: { 33 | app: { 34 | main: './transpiled-js/main.js', 35 | defaultExtension: 'js' 36 | }, 37 | rxjs: { 38 | defaultExtension: 'js' 39 | }, 40 | 'angular-in-memory-web-api': { 41 | main: './index.js', 42 | defaultExtension: 'js' 43 | }, 44 | /** Configuration for ng2-file-upload */ 45 | 'ng2-file-upload' : { 46 | main: './ng2-file-upload.js', 47 | defaultExtension: 'js' 48 | } 49 | /** Configuration for ng2-file-upload */ 50 | } 51 | }); 52 | })(this); -------------------------------------------------------------------------------- /angular2-app/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "es5", 4 | "module": "commonjs", 5 | "moduleResolution": "node", 6 | "sourceMap": true, 7 | "outDir": "app/transpiled-js", 8 | "emitDecoratorMetadata": true, 9 | "experimentalDecorators": true, 10 | "removeComments": false, 11 | "noImplicitAny": false 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /angular2-app/typings.json: -------------------------------------------------------------------------------- 1 | { 2 | "globalDependencies": { 3 | "core-js": "registry:dt/core-js#0.0.0+20160725163759", 4 | "jasmine": "registry:dt/jasmine#2.2.0+20160621224255", 5 | "node": "registry:dt/node#6.0.0+20160909174046" 6 | } 7 | } -------------------------------------------------------------------------------- /angular2-app/typings/globals/core-js/index.d.ts: -------------------------------------------------------------------------------- 1 | // Generated by typings 2 | // Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/25e18b592470e3dddccc826fde2bb8e7610ef863/core-js/core-js.d.ts 3 | declare type PropertyKey = string | number | symbol; 4 | 5 | // ############################################################################################# 6 | // ECMAScript 6: Object & Function 7 | // Modules: es6.object.assign, es6.object.is, es6.object.set-prototype-of, 8 | // es6.object.to-string, es6.function.name and es6.function.has-instance. 9 | // ############################################################################################# 10 | 11 | interface ObjectConstructor { 12 | /** 13 | * Copy the values of all of the enumerable own properties from one or more source objects to a 14 | * target object. Returns the target object. 15 | * @param target The target object to copy to. 16 | * @param source The source object from which to copy properties. 17 | */ 18 | assign(target: T, source: U): T & U; 19 | 20 | /** 21 | * Copy the values of all of the enumerable own properties from one or more source objects to a 22 | * target object. Returns the target object. 23 | * @param target The target object to copy to. 24 | * @param source1 The first source object from which to copy properties. 25 | * @param source2 The second source object from which to copy properties. 26 | */ 27 | assign(target: T, source1: U, source2: V): T & U & V; 28 | 29 | /** 30 | * Copy the values of all of the enumerable own properties from one or more source objects to a 31 | * target object. Returns the target object. 32 | * @param target The target object to copy to. 33 | * @param source1 The first source object from which to copy properties. 34 | * @param source2 The second source object from which to copy properties. 35 | * @param source3 The third source object from which to copy properties. 36 | */ 37 | assign(target: T, source1: U, source2: V, source3: W): T & U & V & W; 38 | 39 | /** 40 | * Copy the values of all of the enumerable own properties from one or more source objects to a 41 | * target object. Returns the target object. 42 | * @param target The target object to copy to. 43 | * @param sources One or more source objects from which to copy properties 44 | */ 45 | assign(target: any, ...sources: any[]): any; 46 | 47 | /** 48 | * Returns true if the values are the same value, false otherwise. 49 | * @param value1 The first value. 50 | * @param value2 The second value. 51 | */ 52 | is(value1: any, value2: any): boolean; 53 | 54 | /** 55 | * Sets the prototype of a specified object o to object proto or null. Returns the object o. 56 | * @param o The object to change its prototype. 57 | * @param proto The value of the new prototype or null. 58 | * @remarks Requires `__proto__` support. 59 | */ 60 | setPrototypeOf(o: any, proto: any): any; 61 | } 62 | 63 | interface Function { 64 | /** 65 | * Returns the name of the function. Function names are read-only and can not be changed. 66 | */ 67 | name: string; 68 | 69 | /** 70 | * Determines if a constructor object recognizes an object as one of the 71 | * constructor’s instances. 72 | * @param value The object to test. 73 | */ 74 | [Symbol.hasInstance](value: any): boolean; 75 | } 76 | 77 | // ############################################################################################# 78 | // ECMAScript 6: Array 79 | // Modules: es6.array.from, es6.array.of, es6.array.copy-within, es6.array.fill, es6.array.find, 80 | // and es6.array.find-index 81 | // ############################################################################################# 82 | 83 | interface Array { 84 | /** 85 | * Returns the value of the first element in the array where predicate is true, and undefined 86 | * otherwise. 87 | * @param predicate find calls predicate once for each element of the array, in ascending 88 | * order, until it finds one where predicate returns true. If such an element is found, find 89 | * immediately returns that element value. Otherwise, find returns undefined. 90 | * @param thisArg If provided, it will be used as the this value for each invocation of 91 | * predicate. If it is not provided, undefined is used instead. 92 | */ 93 | find(predicate: (value: T, index: number, obj: Array) => boolean, thisArg?: any): T; 94 | 95 | /** 96 | * Returns the index of the first element in the array where predicate is true, and undefined 97 | * otherwise. 98 | * @param predicate find calls predicate once for each element of the array, in ascending 99 | * order, until it finds one where predicate returns true. If such an element is found, find 100 | * immediately returns that element value. Otherwise, find returns undefined. 101 | * @param thisArg If provided, it will be used as the this value for each invocation of 102 | * predicate. If it is not provided, undefined is used instead. 103 | */ 104 | findIndex(predicate: (value: T) => boolean, thisArg?: any): number; 105 | 106 | /** 107 | * Returns the this object after filling the section identified by start and end with value 108 | * @param value value to fill array section with 109 | * @param start index to start filling the array at. If start is negative, it is treated as 110 | * length+start where length is the length of the array. 111 | * @param end index to stop filling the array at. If end is negative, it is treated as 112 | * length+end. 113 | */ 114 | fill(value: T, start?: number, end?: number): T[]; 115 | 116 | /** 117 | * Returns the this object after copying a section of the array identified by start and end 118 | * to the same array starting at position target 119 | * @param target If target is negative, it is treated as length+target where length is the 120 | * length of the array. 121 | * @param start If start is negative, it is treated as length+start. If end is negative, it 122 | * is treated as length+end. 123 | * @param end If not specified, length of the this object is used as its default value. 124 | */ 125 | copyWithin(target: number, start: number, end?: number): T[]; 126 | 127 | [Symbol.unscopables]: any; 128 | } 129 | 130 | interface ArrayConstructor { 131 | /** 132 | * Creates an array from an array-like object. 133 | * @param arrayLike An array-like object to convert to an array. 134 | * @param mapfn A mapping function to call on every element of the array. 135 | * @param thisArg Value of 'this' used to invoke the mapfn. 136 | */ 137 | from(arrayLike: ArrayLike, mapfn: (v: T, k: number) => U, thisArg?: any): Array; 138 | 139 | /** 140 | * Creates an array from an iterable object. 141 | * @param iterable An iterable object to convert to an array. 142 | * @param mapfn A mapping function to call on every element of the array. 143 | * @param thisArg Value of 'this' used to invoke the mapfn. 144 | */ 145 | from(iterable: Iterable, mapfn: (v: T, k: number) => U, thisArg?: any): Array; 146 | 147 | /** 148 | * Creates an array from an array-like object. 149 | * @param arrayLike An array-like object to convert to an array. 150 | */ 151 | from(arrayLike: ArrayLike): Array; 152 | 153 | /** 154 | * Creates an array from an iterable object. 155 | * @param iterable An iterable object to convert to an array. 156 | */ 157 | from(iterable: Iterable): Array; 158 | 159 | /** 160 | * Returns a new array from a set of elements. 161 | * @param items A set of elements to include in the new array object. 162 | */ 163 | of(...items: T[]): Array; 164 | } 165 | 166 | // ############################################################################################# 167 | // ECMAScript 6: String & RegExp 168 | // Modules: es6.string.from-code-point, es6.string.raw, es6.string.code-point-at, 169 | // es6.string.ends-with, es6.string.includes, es6.string.repeat, 170 | // es6.string.starts-with, and es6.regexp 171 | // ############################################################################################# 172 | 173 | interface String { 174 | /** 175 | * Returns a nonnegative integer Number less than 1114112 (0x110000) that is the code point 176 | * value of the UTF-16 encoded code point starting at the string element at position pos in 177 | * the String resulting from converting this object to a String. 178 | * If there is no element at that position, the result is undefined. 179 | * If a valid UTF-16 surrogate pair does not begin at pos, the result is the code unit at pos. 180 | */ 181 | codePointAt(pos: number): number; 182 | 183 | /** 184 | * Returns true if searchString appears as a substring of the result of converting this 185 | * object to a String, at one or more positions that are 186 | * greater than or equal to position; otherwise, returns false. 187 | * @param searchString search string 188 | * @param position If position is undefined, 0 is assumed, so as to search all of the String. 189 | */ 190 | includes(searchString: string, position?: number): boolean; 191 | 192 | /** 193 | * Returns true if the sequence of elements of searchString converted to a String is the 194 | * same as the corresponding elements of this object (converted to a String) starting at 195 | * endPosition – length(this). Otherwise returns false. 196 | */ 197 | endsWith(searchString: string, endPosition?: number): boolean; 198 | 199 | /** 200 | * Returns a String value that is made from count copies appended together. If count is 0, 201 | * T is the empty String is returned. 202 | * @param count number of copies to append 203 | */ 204 | repeat(count: number): string; 205 | 206 | /** 207 | * Returns true if the sequence of elements of searchString converted to a String is the 208 | * same as the corresponding elements of this object (converted to a String) starting at 209 | * position. Otherwise returns false. 210 | */ 211 | startsWith(searchString: string, position?: number): boolean; 212 | } 213 | 214 | interface StringConstructor { 215 | /** 216 | * Return the String value whose elements are, in order, the elements in the List elements. 217 | * If length is 0, the empty string is returned. 218 | */ 219 | fromCodePoint(...codePoints: number[]): string; 220 | 221 | /** 222 | * String.raw is intended for use as a tag function of a Tagged Template String. When called 223 | * as such the first argument will be a well formed template call site object and the rest 224 | * parameter will contain the substitution values. 225 | * @param template A well-formed template string call site representation. 226 | * @param substitutions A set of substitution values. 227 | */ 228 | raw(template: TemplateStringsArray, ...substitutions: any[]): string; 229 | } 230 | 231 | interface RegExp { 232 | /** 233 | * Returns a string indicating the flags of the regular expression in question. This field is read-only. 234 | * The characters in this string are sequenced and concatenated in the following order: 235 | * 236 | * - "g" for global 237 | * - "i" for ignoreCase 238 | * - "m" for multiline 239 | * - "u" for unicode 240 | * - "y" for sticky 241 | * 242 | * If no flags are set, the value is the empty string. 243 | */ 244 | flags: string; 245 | } 246 | 247 | // ############################################################################################# 248 | // ECMAScript 6: Number & Math 249 | // Modules: es6.number.constructor, es6.number.statics, and es6.math 250 | // ############################################################################################# 251 | 252 | interface NumberConstructor { 253 | /** 254 | * The value of Number.EPSILON is the difference between 1 and the smallest value greater than 1 255 | * that is representable as a Number value, which is approximately: 256 | * 2.2204460492503130808472633361816 x 10‍−‍16. 257 | */ 258 | EPSILON: number; 259 | 260 | /** 261 | * Returns true if passed value is finite. 262 | * Unlike the global isFininte, Number.isFinite doesn't forcibly convert the parameter to a 263 | * number. Only finite values of the type number, result in true. 264 | * @param number A numeric value. 265 | */ 266 | isFinite(number: number): boolean; 267 | 268 | /** 269 | * Returns true if the value passed is an integer, false otherwise. 270 | * @param number A numeric value. 271 | */ 272 | isInteger(number: number): boolean; 273 | 274 | /** 275 | * Returns a Boolean value that indicates whether a value is the reserved value NaN (not a 276 | * number). Unlike the global isNaN(), Number.isNaN() doesn't forcefully convert the parameter 277 | * to a number. Only values of the type number, that are also NaN, result in true. 278 | * @param number A numeric value. 279 | */ 280 | isNaN(number: number): boolean; 281 | 282 | /** 283 | * Returns true if the value passed is a safe integer. 284 | * @param number A numeric value. 285 | */ 286 | isSafeInteger(number: number): boolean; 287 | 288 | /** 289 | * The value of the largest integer n such that n and n + 1 are both exactly representable as 290 | * a Number value. 291 | * The value of Number.MIN_SAFE_INTEGER is 9007199254740991 2^53 − 1. 292 | */ 293 | MAX_SAFE_INTEGER: number; 294 | 295 | /** 296 | * The value of the smallest integer n such that n and n − 1 are both exactly representable as 297 | * a Number value. 298 | * The value of Number.MIN_SAFE_INTEGER is −9007199254740991 (−(2^53 − 1)). 299 | */ 300 | MIN_SAFE_INTEGER: number; 301 | 302 | /** 303 | * Converts a string to a floating-point number. 304 | * @param string A string that contains a floating-point number. 305 | */ 306 | parseFloat(string: string): number; 307 | 308 | /** 309 | * Converts A string to an integer. 310 | * @param s A string to convert into a number. 311 | * @param radix A value between 2 and 36 that specifies the base of the number in numString. 312 | * If this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal. 313 | * All other strings are considered decimal. 314 | */ 315 | parseInt(string: string, radix?: number): number; 316 | } 317 | 318 | interface Math { 319 | /** 320 | * Returns the number of leading zero bits in the 32-bit binary representation of a number. 321 | * @param x A numeric expression. 322 | */ 323 | clz32(x: number): number; 324 | 325 | /** 326 | * Returns the result of 32-bit multiplication of two numbers. 327 | * @param x First number 328 | * @param y Second number 329 | */ 330 | imul(x: number, y: number): number; 331 | 332 | /** 333 | * Returns the sign of the x, indicating whether x is positive, negative or zero. 334 | * @param x The numeric expression to test 335 | */ 336 | sign(x: number): number; 337 | 338 | /** 339 | * Returns the base 10 logarithm of a number. 340 | * @param x A numeric expression. 341 | */ 342 | log10(x: number): number; 343 | 344 | /** 345 | * Returns the base 2 logarithm of a number. 346 | * @param x A numeric expression. 347 | */ 348 | log2(x: number): number; 349 | 350 | /** 351 | * Returns the natural logarithm of 1 + x. 352 | * @param x A numeric expression. 353 | */ 354 | log1p(x: number): number; 355 | 356 | /** 357 | * Returns the result of (e^x - 1) of x (e raised to the power of x, where e is the base of 358 | * the natural logarithms). 359 | * @param x A numeric expression. 360 | */ 361 | expm1(x: number): number; 362 | 363 | /** 364 | * Returns the hyperbolic cosine of a number. 365 | * @param x A numeric expression that contains an angle measured in radians. 366 | */ 367 | cosh(x: number): number; 368 | 369 | /** 370 | * Returns the hyperbolic sine of a number. 371 | * @param x A numeric expression that contains an angle measured in radians. 372 | */ 373 | sinh(x: number): number; 374 | 375 | /** 376 | * Returns the hyperbolic tangent of a number. 377 | * @param x A numeric expression that contains an angle measured in radians. 378 | */ 379 | tanh(x: number): number; 380 | 381 | /** 382 | * Returns the inverse hyperbolic cosine of a number. 383 | * @param x A numeric expression that contains an angle measured in radians. 384 | */ 385 | acosh(x: number): number; 386 | 387 | /** 388 | * Returns the inverse hyperbolic sine of a number. 389 | * @param x A numeric expression that contains an angle measured in radians. 390 | */ 391 | asinh(x: number): number; 392 | 393 | /** 394 | * Returns the inverse hyperbolic tangent of a number. 395 | * @param x A numeric expression that contains an angle measured in radians. 396 | */ 397 | atanh(x: number): number; 398 | 399 | /** 400 | * Returns the square root of the sum of squares of its arguments. 401 | * @param values Values to compute the square root for. 402 | * If no arguments are passed, the result is +0. 403 | * If there is only one argument, the result is the absolute value. 404 | * If any argument is +Infinity or -Infinity, the result is +Infinity. 405 | * If any argument is NaN, the result is NaN. 406 | * If all arguments are either +0 or −0, the result is +0. 407 | */ 408 | hypot(...values: number[]): number; 409 | 410 | /** 411 | * Returns the integral part of the a numeric expression, x, removing any fractional digits. 412 | * If x is already an integer, the result is x. 413 | * @param x A numeric expression. 414 | */ 415 | trunc(x: number): number; 416 | 417 | /** 418 | * Returns the nearest single precision float representation of a number. 419 | * @param x A numeric expression. 420 | */ 421 | fround(x: number): number; 422 | 423 | /** 424 | * Returns an implementation-dependent approximation to the cube root of number. 425 | * @param x A numeric expression. 426 | */ 427 | cbrt(x: number): number; 428 | } 429 | 430 | // ############################################################################################# 431 | // ECMAScript 6: Symbols 432 | // Modules: es6.symbol 433 | // ############################################################################################# 434 | 435 | interface Symbol { 436 | /** Returns a string representation of an object. */ 437 | toString(): string; 438 | 439 | [Symbol.toStringTag]: string; 440 | } 441 | 442 | interface SymbolConstructor { 443 | /** 444 | * A reference to the prototype. 445 | */ 446 | prototype: Symbol; 447 | 448 | /** 449 | * Returns a new unique Symbol value. 450 | * @param description Description of the new Symbol object. 451 | */ 452 | (description?: string|number): symbol; 453 | 454 | /** 455 | * Returns a Symbol object from the global symbol registry matching the given key if found. 456 | * Otherwise, returns a new symbol with this key. 457 | * @param key key to search for. 458 | */ 459 | for(key: string): symbol; 460 | 461 | /** 462 | * Returns a key from the global symbol registry matching the given Symbol if found. 463 | * Otherwise, returns a undefined. 464 | * @param sym Symbol to find the key for. 465 | */ 466 | keyFor(sym: symbol): string; 467 | 468 | // Well-known Symbols 469 | 470 | /** 471 | * A method that determines if a constructor object recognizes an object as one of the 472 | * constructor’s instances. Called by the semantics of the instanceof operator. 473 | */ 474 | hasInstance: symbol; 475 | 476 | /** 477 | * A Boolean value that if true indicates that an object should flatten to its array elements 478 | * by Array.prototype.concat. 479 | */ 480 | isConcatSpreadable: symbol; 481 | 482 | /** 483 | * A method that returns the default iterator for an object. Called by the semantics of the 484 | * for-of statement. 485 | */ 486 | iterator: symbol; 487 | 488 | /** 489 | * A regular expression method that matches the regular expression against a string. Called 490 | * by the String.prototype.match method. 491 | */ 492 | match: symbol; 493 | 494 | /** 495 | * A regular expression method that replaces matched substrings of a string. Called by the 496 | * String.prototype.replace method. 497 | */ 498 | replace: symbol; 499 | 500 | /** 501 | * A regular expression method that returns the index within a string that matches the 502 | * regular expression. Called by the String.prototype.search method. 503 | */ 504 | search: symbol; 505 | 506 | /** 507 | * A function valued property that is the constructor function that is used to create 508 | * derived objects. 509 | */ 510 | species: symbol; 511 | 512 | /** 513 | * A regular expression method that splits a string at the indices that match the regular 514 | * expression. Called by the String.prototype.split method. 515 | */ 516 | split: symbol; 517 | 518 | /** 519 | * A method that converts an object to a corresponding primitive value.Called by the ToPrimitive 520 | * abstract operation. 521 | */ 522 | toPrimitive: symbol; 523 | 524 | /** 525 | * A String value that is used in the creation of the default string description of an object. 526 | * Called by the built-in method Object.prototype.toString. 527 | */ 528 | toStringTag: symbol; 529 | 530 | /** 531 | * An Object whose own property names are property names that are excluded from the with 532 | * environment bindings of the associated objects. 533 | */ 534 | unscopables: symbol; 535 | 536 | /** 537 | * Non-standard. Use simple mode for core-js symbols. See https://github.com/zloirock/core-js/#caveats-when-using-symbol-polyfill 538 | */ 539 | useSimple(): void; 540 | 541 | /** 542 | * Non-standard. Use setter mode for core-js symbols. See https://github.com/zloirock/core-js/#caveats-when-using-symbol-polyfill 543 | */ 544 | userSetter(): void; 545 | } 546 | 547 | declare var Symbol: SymbolConstructor; 548 | 549 | interface Object { 550 | /** 551 | * Determines whether an object has a property with the specified name. 552 | * @param v A property name. 553 | */ 554 | hasOwnProperty(v: PropertyKey): boolean; 555 | 556 | /** 557 | * Determines whether a specified property is enumerable. 558 | * @param v A property name. 559 | */ 560 | propertyIsEnumerable(v: PropertyKey): boolean; 561 | } 562 | 563 | interface ObjectConstructor { 564 | /** 565 | * Returns an array of all symbol properties found directly on object o. 566 | * @param o Object to retrieve the symbols from. 567 | */ 568 | getOwnPropertySymbols(o: any): symbol[]; 569 | 570 | /** 571 | * Gets the own property descriptor of the specified object. 572 | * An own property descriptor is one that is defined directly on the object and is not 573 | * inherited from the object's prototype. 574 | * @param o Object that contains the property. 575 | * @param p Name of the property. 576 | */ 577 | getOwnPropertyDescriptor(o: any, propertyKey: PropertyKey): PropertyDescriptor; 578 | 579 | /** 580 | * Adds a property to an object, or modifies attributes of an existing property. 581 | * @param o Object on which to add or modify the property. This can be a native JavaScript 582 | * object (that is, a user-defined object or a built in object) or a DOM object. 583 | * @param p The property name. 584 | * @param attributes Descriptor for the property. It can be for a data property or an accessor 585 | * property. 586 | */ 587 | defineProperty(o: any, propertyKey: PropertyKey, attributes: PropertyDescriptor): any; 588 | } 589 | 590 | interface Math { 591 | [Symbol.toStringTag]: string; 592 | } 593 | 594 | interface JSON { 595 | [Symbol.toStringTag]: string; 596 | } 597 | 598 | // ############################################################################################# 599 | // ECMAScript 6: Collections 600 | // Modules: es6.map, es6.set, es6.weak-map, and es6.weak-set 601 | // ############################################################################################# 602 | 603 | interface Map { 604 | clear(): void; 605 | delete(key: K): boolean; 606 | forEach(callbackfn: (value: V, index: K, map: Map) => void, thisArg?: any): void; 607 | get(key: K): V; 608 | has(key: K): boolean; 609 | set(key: K, value?: V): Map; 610 | size: number; 611 | } 612 | 613 | interface MapConstructor { 614 | new (): Map; 615 | new (iterable: Iterable<[K, V]>): Map; 616 | prototype: Map; 617 | } 618 | 619 | declare var Map: MapConstructor; 620 | 621 | interface Set { 622 | add(value: T): Set; 623 | clear(): void; 624 | delete(value: T): boolean; 625 | forEach(callbackfn: (value: T, index: T, set: Set) => void, thisArg?: any): void; 626 | has(value: T): boolean; 627 | size: number; 628 | } 629 | 630 | interface SetConstructor { 631 | new (): Set; 632 | new (iterable: Iterable): Set; 633 | prototype: Set; 634 | } 635 | 636 | declare var Set: SetConstructor; 637 | 638 | interface WeakMap { 639 | delete(key: K): boolean; 640 | get(key: K): V; 641 | has(key: K): boolean; 642 | set(key: K, value?: V): WeakMap; 643 | } 644 | 645 | interface WeakMapConstructor { 646 | new (): WeakMap; 647 | new (iterable: Iterable<[K, V]>): WeakMap; 648 | prototype: WeakMap; 649 | } 650 | 651 | declare var WeakMap: WeakMapConstructor; 652 | 653 | interface WeakSet { 654 | add(value: T): WeakSet; 655 | delete(value: T): boolean; 656 | has(value: T): boolean; 657 | } 658 | 659 | interface WeakSetConstructor { 660 | new (): WeakSet; 661 | new (iterable: Iterable): WeakSet; 662 | prototype: WeakSet; 663 | } 664 | 665 | declare var WeakSet: WeakSetConstructor; 666 | 667 | // ############################################################################################# 668 | // ECMAScript 6: Iterators 669 | // Modules: es6.string.iterator, es6.array.iterator, es6.map, es6.set, web.dom.iterable 670 | // ############################################################################################# 671 | 672 | interface IteratorResult { 673 | done: boolean; 674 | value?: T; 675 | } 676 | 677 | interface Iterator { 678 | next(value?: any): IteratorResult; 679 | return?(value?: any): IteratorResult; 680 | throw?(e?: any): IteratorResult; 681 | } 682 | 683 | interface Iterable { 684 | [Symbol.iterator](): Iterator; 685 | } 686 | 687 | interface IterableIterator extends Iterator { 688 | [Symbol.iterator](): IterableIterator; 689 | } 690 | 691 | interface String { 692 | /** Iterator */ 693 | [Symbol.iterator](): IterableIterator; 694 | } 695 | 696 | interface Array { 697 | /** Iterator */ 698 | [Symbol.iterator](): IterableIterator; 699 | 700 | /** 701 | * Returns an array of key, value pairs for every entry in the array 702 | */ 703 | entries(): IterableIterator<[number, T]>; 704 | 705 | /** 706 | * Returns an list of keys in the array 707 | */ 708 | keys(): IterableIterator; 709 | 710 | /** 711 | * Returns an list of values in the array 712 | */ 713 | values(): IterableIterator; 714 | } 715 | 716 | interface Map { 717 | entries(): IterableIterator<[K, V]>; 718 | keys(): IterableIterator; 719 | values(): IterableIterator; 720 | [Symbol.iterator](): IterableIterator<[K, V]>; 721 | } 722 | 723 | interface Set { 724 | entries(): IterableIterator<[T, T]>; 725 | keys(): IterableIterator; 726 | values(): IterableIterator; 727 | [Symbol.iterator](): IterableIterator; 728 | } 729 | 730 | interface NodeList { 731 | [Symbol.iterator](): IterableIterator; 732 | } 733 | 734 | interface $for extends IterableIterator { 735 | of(callbackfn: (value: T, key: any) => void, thisArg?: any): void; 736 | array(): T[]; 737 | array(callbackfn: (value: T, key: any) => U, thisArg?: any): U[]; 738 | filter(callbackfn: (value: T, key: any) => boolean, thisArg?: any): $for; 739 | map(callbackfn: (value: T, key: any) => U, thisArg?: any): $for; 740 | } 741 | 742 | declare function $for(iterable: Iterable): $for; 743 | 744 | // ############################################################################################# 745 | // ECMAScript 6: Promises 746 | // Modules: es6.promise 747 | // ############################################################################################# 748 | 749 | interface PromiseLike { 750 | /** 751 | * Attaches callbacks for the resolution and/or rejection of the Promise. 752 | * @param onfulfilled The callback to execute when the Promise is resolved. 753 | * @param onrejected The callback to execute when the Promise is rejected. 754 | * @returns A Promise for the completion of which ever callback is executed. 755 | */ 756 | then(onfulfilled?: (value: T) => TResult | PromiseLike, onrejected?: (reason: any) => TResult | PromiseLike): PromiseLike; 757 | then(onfulfilled?: (value: T) => TResult | PromiseLike, onrejected?: (reason: any) => void): PromiseLike; 758 | } 759 | 760 | /** 761 | * Represents the completion of an asynchronous operation 762 | */ 763 | interface Promise { 764 | /** 765 | * Attaches callbacks for the resolution and/or rejection of the Promise. 766 | * @param onfulfilled The callback to execute when the Promise is resolved. 767 | * @param onrejected The callback to execute when the Promise is rejected. 768 | * @returns A Promise for the completion of which ever callback is executed. 769 | */ 770 | then(onfulfilled?: (value: T) => TResult | PromiseLike, onrejected?: (reason: any) => TResult | PromiseLike): Promise; 771 | then(onfulfilled?: (value: T) => TResult | PromiseLike, onrejected?: (reason: any) => void): Promise; 772 | 773 | /** 774 | * Attaches a callback for only the rejection of the Promise. 775 | * @param onrejected The callback to execute when the Promise is rejected. 776 | * @returns A Promise for the completion of the callback. 777 | */ 778 | catch(onrejected?: (reason: any) => T | PromiseLike): Promise; 779 | catch(onrejected?: (reason: any) => void): Promise; 780 | } 781 | 782 | interface PromiseConstructor { 783 | /** 784 | * A reference to the prototype. 785 | */ 786 | prototype: Promise; 787 | 788 | /** 789 | * Creates a new Promise. 790 | * @param executor A callback used to initialize the promise. This callback is passed two arguments: 791 | * a resolve callback used resolve the promise with a value or the result of another promise, 792 | * and a reject callback used to reject the promise with a provided reason or error. 793 | */ 794 | new (executor: (resolve: (value?: T | PromiseLike) => void, reject: (reason?: any) => void) => void): Promise; 795 | 796 | /** 797 | * Creates a Promise that is resolved with an array of results when all of the provided Promises 798 | * resolve, or rejected when any Promise is rejected. 799 | * @param values An array of Promises. 800 | * @returns A new Promise. 801 | */ 802 | all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike, T9 | PromiseLike, T10 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6, T7, T8, T9, T10]>; 803 | all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike, T9 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6, T7, T8, T9]>; 804 | all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6, T7, T8]>; 805 | all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6, T7]>; 806 | all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6]>; 807 | all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike]): Promise<[T1, T2, T3, T4, T5]>; 808 | all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike ]): Promise<[T1, T2, T3, T4]>; 809 | all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike]): Promise<[T1, T2, T3]>; 810 | all(values: [T1 | PromiseLike, T2 | PromiseLike]): Promise<[T1, T2]>; 811 | all(values: Iterable>): Promise; 812 | 813 | /** 814 | * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved 815 | * or rejected. 816 | * @param values An array of Promises. 817 | * @returns A new Promise. 818 | */ 819 | race(values: Iterable>): Promise; 820 | 821 | /** 822 | * Creates a new rejected promise for the provided reason. 823 | * @param reason The reason the promise was rejected. 824 | * @returns A new rejected Promise. 825 | */ 826 | reject(reason: any): Promise; 827 | 828 | /** 829 | * Creates a new rejected promise for the provided reason. 830 | * @param reason The reason the promise was rejected. 831 | * @returns A new rejected Promise. 832 | */ 833 | reject(reason: any): Promise; 834 | 835 | /** 836 | * Creates a new resolved promise for the provided value. 837 | * @param value A promise. 838 | * @returns A promise whose internal state matches the provided promise. 839 | */ 840 | resolve(value: T | PromiseLike): Promise; 841 | 842 | /** 843 | * Creates a new resolved promise . 844 | * @returns A resolved promise. 845 | */ 846 | resolve(): Promise; 847 | } 848 | 849 | declare var Promise: PromiseConstructor; 850 | 851 | // ############################################################################################# 852 | // ECMAScript 6: Reflect 853 | // Modules: es6.reflect 854 | // ############################################################################################# 855 | 856 | declare namespace Reflect { 857 | function apply(target: Function, thisArgument: any, argumentsList: ArrayLike): any; 858 | function construct(target: Function, argumentsList: ArrayLike, newTarget?: any): any; 859 | function defineProperty(target: any, propertyKey: PropertyKey, attributes: PropertyDescriptor): boolean; 860 | function deleteProperty(target: any, propertyKey: PropertyKey): boolean; 861 | function enumerate(target: any): IterableIterator; 862 | function get(target: any, propertyKey: PropertyKey, receiver?: any): any; 863 | function getOwnPropertyDescriptor(target: any, propertyKey: PropertyKey): PropertyDescriptor; 864 | function getPrototypeOf(target: any): any; 865 | function has(target: any, propertyKey: PropertyKey): boolean; 866 | function isExtensible(target: any): boolean; 867 | function ownKeys(target: any): Array; 868 | function preventExtensions(target: any): boolean; 869 | function set(target: any, propertyKey: PropertyKey, value: any, receiver?: any): boolean; 870 | function setPrototypeOf(target: any, proto: any): boolean; 871 | } 872 | 873 | // ############################################################################################# 874 | // ECMAScript 7 875 | // Modules: es7.array.includes, es7.string.at, es7.string.lpad, es7.string.rpad, 876 | // es7.object.to-array, es7.object.get-own-property-descriptors, es7.regexp.escape, 877 | // es7.map.to-json, and es7.set.to-json 878 | // ############################################################################################# 879 | 880 | interface Array { 881 | includes(value: T, fromIndex?: number): boolean; 882 | } 883 | 884 | interface String { 885 | at(index: number): string; 886 | lpad(length: number, fillStr?: string): string; 887 | rpad(length: number, fillStr?: string): string; 888 | } 889 | 890 | interface ObjectConstructor { 891 | values(object: any): any[]; 892 | entries(object: any): [string, any][]; 893 | getOwnPropertyDescriptors(object: any): PropertyDescriptorMap; 894 | } 895 | 896 | interface RegExpConstructor { 897 | escape(str: string): string; 898 | } 899 | 900 | interface Map { 901 | toJSON(): any; 902 | } 903 | 904 | interface Set { 905 | toJSON(): any; 906 | } 907 | 908 | // ############################################################################################# 909 | // Mozilla JavaScript: Array generics 910 | // Modules: js.array.statics 911 | // ############################################################################################# 912 | 913 | interface ArrayConstructor { 914 | /** 915 | * Appends new elements to an array, and returns the new length of the array. 916 | * @param items New elements of the Array. 917 | */ 918 | push(array: ArrayLike, ...items: T[]): number; 919 | /** 920 | * Removes the last element from an array and returns it. 921 | */ 922 | pop(array: ArrayLike): T; 923 | /** 924 | * Combines two or more arrays. 925 | * @param items Additional items to add to the end of array1. 926 | */ 927 | concat(array: ArrayLike, ...items: (T[]| T)[]): T[]; 928 | /** 929 | * Adds all the elements of an array separated by the specified separator string. 930 | * @param separator A string used to separate one element of an array from the next in the resulting String. If omitted, the array elements are separated with a comma. 931 | */ 932 | join(array: ArrayLike, separator?: string): string; 933 | /** 934 | * Reverses the elements in an Array. 935 | */ 936 | reverse(array: ArrayLike): T[]; 937 | /** 938 | * Removes the first element from an array and returns it. 939 | */ 940 | shift(array: ArrayLike): T; 941 | /** 942 | * Returns a section of an array. 943 | * @param start The beginning of the specified portion of the array. 944 | * @param end The end of the specified portion of the array. 945 | */ 946 | slice(array: ArrayLike, start?: number, end?: number): T[]; 947 | 948 | /** 949 | * Sorts an array. 950 | * @param compareFn The name of the function used to determine the order of the elements. If omitted, the elements are sorted in ascending, ASCII character order. 951 | */ 952 | sort(array: ArrayLike, compareFn?: (a: T, b: T) => number): T[]; 953 | 954 | /** 955 | * Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements. 956 | * @param start The zero-based location in the array from which to start removing elements. 957 | */ 958 | splice(array: ArrayLike, start: number): T[]; 959 | 960 | /** 961 | * Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements. 962 | * @param start The zero-based location in the array from which to start removing elements. 963 | * @param deleteCount The number of elements to remove. 964 | * @param items Elements to insert into the array in place of the deleted elements. 965 | */ 966 | splice(array: ArrayLike, start: number, deleteCount: number, ...items: T[]): T[]; 967 | 968 | /** 969 | * Inserts new elements at the start of an array. 970 | * @param items Elements to insert at the start of the Array. 971 | */ 972 | unshift(array: ArrayLike, ...items: T[]): number; 973 | 974 | /** 975 | * Returns the index of the first occurrence of a value in an array. 976 | * @param searchElement The value to locate in the array. 977 | * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0. 978 | */ 979 | indexOf(array: ArrayLike, searchElement: T, fromIndex?: number): number; 980 | 981 | /** 982 | * Returns the index of the last occurrence of a specified value in an array. 983 | * @param searchElement The value to locate in the array. 984 | * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at the last index in the array. 985 | */ 986 | lastIndexOf(array: ArrayLike, earchElement: T, fromIndex?: number): number; 987 | 988 | /** 989 | * Determines whether all the members of an array satisfy the specified test. 990 | * @param callbackfn A function that accepts up to three arguments. The every method calls the callbackfn function for each element in array1 until the callbackfn returns false, or until the end of the array. 991 | * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value. 992 | */ 993 | every(array: ArrayLike, callbackfn: (value: T, index: number, array: T[]) => boolean, thisArg?: any): boolean; 994 | 995 | /** 996 | * Determines whether the specified callback function returns true for any element of an array. 997 | * @param callbackfn A function that accepts up to three arguments. The some method calls the callbackfn function for each element in array1 until the callbackfn returns true, or until the end of the array. 998 | * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value. 999 | */ 1000 | some(array: ArrayLike, callbackfn: (value: T, index: number, array: T[]) => boolean, thisArg?: any): boolean; 1001 | 1002 | /** 1003 | * Performs the specified action for each element in an array. 1004 | * @param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array. 1005 | * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value. 1006 | */ 1007 | forEach(array: ArrayLike, callbackfn: (value: T, index: number, array: T[]) => void, thisArg?: any): void; 1008 | 1009 | /** 1010 | * Calls a defined callback function on each element of an array, and returns an array that contains the results. 1011 | * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array. 1012 | * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value. 1013 | */ 1014 | map(array: ArrayLike, callbackfn: (value: T, index: number, array: T[]) => U, thisArg?: any): U[]; 1015 | 1016 | /** 1017 | * Returns the elements of an array that meet the condition specified in a callback function. 1018 | * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array. 1019 | * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value. 1020 | */ 1021 | filter(array: ArrayLike, callbackfn: (value: T, index: number, array: T[]) => boolean, thisArg?: any): T[]; 1022 | 1023 | /** 1024 | * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function. 1025 | * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array. 1026 | * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value. 1027 | */ 1028 | reduce(array: ArrayLike, callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: T[]) => U, initialValue: U): U; 1029 | 1030 | /** 1031 | * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function. 1032 | * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array. 1033 | * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value. 1034 | */ 1035 | reduce(array: ArrayLike, callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T, initialValue?: T): T; 1036 | 1037 | /** 1038 | * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function. 1039 | * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array. 1040 | * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value. 1041 | */ 1042 | reduceRight(array: ArrayLike, callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: T[]) => U, initialValue: U): U; 1043 | 1044 | /** 1045 | * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function. 1046 | * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array. 1047 | * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value. 1048 | */ 1049 | reduceRight(array: ArrayLike, callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T, initialValue?: T): T; 1050 | 1051 | /** 1052 | * Returns an array of key, value pairs for every entry in the array 1053 | */ 1054 | entries(array: ArrayLike): IterableIterator<[number, T]>; 1055 | 1056 | /** 1057 | * Returns an list of keys in the array 1058 | */ 1059 | keys(array: ArrayLike): IterableIterator; 1060 | 1061 | /** 1062 | * Returns an list of values in the array 1063 | */ 1064 | values(array: ArrayLike): IterableIterator; 1065 | 1066 | /** 1067 | * Returns the value of the first element in the array where predicate is true, and undefined 1068 | * otherwise. 1069 | * @param predicate find calls predicate once for each element of the array, in ascending 1070 | * order, until it finds one where predicate returns true. If such an element is found, find 1071 | * immediately returns that element value. Otherwise, find returns undefined. 1072 | * @param thisArg If provided, it will be used as the this value for each invocation of 1073 | * predicate. If it is not provided, undefined is used instead. 1074 | */ 1075 | find(array: ArrayLike, predicate: (value: T, index: number, obj: Array) => boolean, thisArg?: any): T; 1076 | 1077 | /** 1078 | * Returns the index of the first element in the array where predicate is true, and undefined 1079 | * otherwise. 1080 | * @param predicate find calls predicate once for each element of the array, in ascending 1081 | * order, until it finds one where predicate returns true. If such an element is found, find 1082 | * immediately returns that element value. Otherwise, find returns undefined. 1083 | * @param thisArg If provided, it will be used as the this value for each invocation of 1084 | * predicate. If it is not provided, undefined is used instead. 1085 | */ 1086 | findIndex(array: ArrayLike, predicate: (value: T) => boolean, thisArg?: any): number; 1087 | 1088 | /** 1089 | * Returns the this object after filling the section identified by start and end with value 1090 | * @param value value to fill array section with 1091 | * @param start index to start filling the array at. If start is negative, it is treated as 1092 | * length+start where length is the length of the array. 1093 | * @param end index to stop filling the array at. If end is negative, it is treated as 1094 | * length+end. 1095 | */ 1096 | fill(array: ArrayLike, value: T, start?: number, end?: number): T[]; 1097 | 1098 | /** 1099 | * Returns the this object after copying a section of the array identified by start and end 1100 | * to the same array starting at position target 1101 | * @param target If target is negative, it is treated as length+target where length is the 1102 | * length of the array. 1103 | * @param start If start is negative, it is treated as length+start. If end is negative, it 1104 | * is treated as length+end. 1105 | * @param end If not specified, length of the this object is used as its default value. 1106 | */ 1107 | copyWithin(array: ArrayLike, target: number, start: number, end?: number): T[]; 1108 | 1109 | includes(array: ArrayLike, value: T, fromIndex?: number): boolean; 1110 | turn(array: ArrayLike, callbackfn: (memo: U, value: T, index: number, array: Array) => void, memo?: U): U; 1111 | turn(array: ArrayLike, callbackfn: (memo: Array, value: T, index: number, array: Array) => void, memo?: Array): Array; 1112 | } 1113 | 1114 | // ############################################################################################# 1115 | // Object - https://github.com/zloirock/core-js/#object 1116 | // Modules: core.object 1117 | // ############################################################################################# 1118 | 1119 | interface ObjectConstructor { 1120 | /** 1121 | * Non-standard. 1122 | */ 1123 | isObject(value: any): boolean; 1124 | 1125 | /** 1126 | * Non-standard. 1127 | */ 1128 | classof(value: any): string; 1129 | 1130 | /** 1131 | * Non-standard. 1132 | */ 1133 | define(target: T, mixin: any): T; 1134 | 1135 | /** 1136 | * Non-standard. 1137 | */ 1138 | make(proto: T, mixin?: any): T; 1139 | } 1140 | 1141 | // ############################################################################################# 1142 | // Console - https://github.com/zloirock/core-js/#console 1143 | // Modules: core.log 1144 | // ############################################################################################# 1145 | 1146 | interface Log extends Console { 1147 | (message?: any, ...optionalParams: any[]): void; 1148 | enable(): void; 1149 | disable(): void; 1150 | } 1151 | 1152 | /** 1153 | * Non-standard. 1154 | */ 1155 | declare var log: Log; 1156 | 1157 | // ############################################################################################# 1158 | // Dict - https://github.com/zloirock/core-js/#dict 1159 | // Modules: core.dict 1160 | // ############################################################################################# 1161 | 1162 | interface Dict { 1163 | [key: string]: T; 1164 | [key: number]: T; 1165 | //[key: symbol]: T; 1166 | } 1167 | 1168 | interface DictConstructor { 1169 | prototype: Dict; 1170 | 1171 | new (value?: Dict): Dict; 1172 | new (value?: any): Dict; 1173 | (value?: Dict): Dict; 1174 | (value?: any): Dict; 1175 | 1176 | isDict(value: any): boolean; 1177 | values(object: Dict): IterableIterator; 1178 | keys(object: Dict): IterableIterator; 1179 | entries(object: Dict): IterableIterator<[PropertyKey, T]>; 1180 | has(object: Dict, key: PropertyKey): boolean; 1181 | get(object: Dict, key: PropertyKey): T; 1182 | set(object: Dict, key: PropertyKey, value: T): Dict; 1183 | forEach(object: Dict, callbackfn: (value: T, key: PropertyKey, dict: Dict) => void, thisArg?: any): void; 1184 | map(object: Dict, callbackfn: (value: T, key: PropertyKey, dict: Dict) => U, thisArg?: any): Dict; 1185 | mapPairs(object: Dict, callbackfn: (value: T, key: PropertyKey, dict: Dict) => [PropertyKey, U], thisArg?: any): Dict; 1186 | filter(object: Dict, callbackfn: (value: T, key: PropertyKey, dict: Dict) => boolean, thisArg?: any): Dict; 1187 | some(object: Dict, callbackfn: (value: T, key: PropertyKey, dict: Dict) => boolean, thisArg?: any): boolean; 1188 | every(object: Dict, callbackfn: (value: T, key: PropertyKey, dict: Dict) => boolean, thisArg?: any): boolean; 1189 | find(object: Dict, callbackfn: (value: T, key: PropertyKey, dict: Dict) => boolean, thisArg?: any): T; 1190 | findKey(object: Dict, callbackfn: (value: T, key: PropertyKey, dict: Dict) => boolean, thisArg?: any): PropertyKey; 1191 | keyOf(object: Dict, value: T): PropertyKey; 1192 | includes(object: Dict, value: T): boolean; 1193 | reduce(object: Dict, callbackfn: (previousValue: U, value: T, key: PropertyKey, dict: Dict) => U, initialValue: U): U; 1194 | reduce(object: Dict, callbackfn: (previousValue: T, value: T, key: PropertyKey, dict: Dict) => T, initialValue?: T): T; 1195 | turn(object: Dict, callbackfn: (memo: Dict, value: T, key: PropertyKey, dict: Dict) => void, memo: Dict): Dict; 1196 | turn(object: Dict, callbackfn: (memo: Dict, value: T, key: PropertyKey, dict: Dict) => void, memo?: Dict): Dict; 1197 | } 1198 | 1199 | /** 1200 | * Non-standard. 1201 | */ 1202 | declare var Dict: DictConstructor; 1203 | 1204 | // ############################################################################################# 1205 | // Partial application - https://github.com/zloirock/core-js/#partial-application 1206 | // Modules: core.function.part 1207 | // ############################################################################################# 1208 | 1209 | interface Function { 1210 | /** 1211 | * Non-standard. 1212 | */ 1213 | part(...args: any[]): any; 1214 | } 1215 | 1216 | // ############################################################################################# 1217 | // Date formatting - https://github.com/zloirock/core-js/#date-formatting 1218 | // Modules: core.date 1219 | // ############################################################################################# 1220 | 1221 | interface Date { 1222 | /** 1223 | * Non-standard. 1224 | */ 1225 | format(template: string, locale?: string): string; 1226 | 1227 | /** 1228 | * Non-standard. 1229 | */ 1230 | formatUTC(template: string, locale?: string): string; 1231 | } 1232 | 1233 | // ############################################################################################# 1234 | // Array - https://github.com/zloirock/core-js/#array 1235 | // Modules: core.array.turn 1236 | // ############################################################################################# 1237 | 1238 | interface Array { 1239 | /** 1240 | * Non-standard. 1241 | */ 1242 | turn(callbackfn: (memo: U, value: T, index: number, array: Array) => void, memo?: U): U; 1243 | 1244 | /** 1245 | * Non-standard. 1246 | */ 1247 | turn(callbackfn: (memo: Array, value: T, index: number, array: Array) => void, memo?: Array): Array; 1248 | } 1249 | 1250 | // ############################################################################################# 1251 | // Number - https://github.com/zloirock/core-js/#number 1252 | // Modules: core.number.iterator 1253 | // ############################################################################################# 1254 | 1255 | interface Number { 1256 | /** 1257 | * Non-standard. 1258 | */ 1259 | [Symbol.iterator](): IterableIterator; 1260 | } 1261 | 1262 | // ############################################################################################# 1263 | // Escaping characters - https://github.com/zloirock/core-js/#escaping-characters 1264 | // Modules: core.string.escape-html 1265 | // ############################################################################################# 1266 | 1267 | interface String { 1268 | /** 1269 | * Non-standard. 1270 | */ 1271 | escapeHTML(): string; 1272 | 1273 | /** 1274 | * Non-standard. 1275 | */ 1276 | unescapeHTML(): string; 1277 | } 1278 | 1279 | // ############################################################################################# 1280 | // delay - https://github.com/zloirock/core-js/#delay 1281 | // Modules: core.delay 1282 | // ############################################################################################# 1283 | 1284 | declare function delay(msec: number): Promise; 1285 | 1286 | declare namespace core { 1287 | var version: string; 1288 | 1289 | namespace Reflect { 1290 | function apply(target: Function, thisArgument: any, argumentsList: ArrayLike): any; 1291 | function construct(target: Function, argumentsList: ArrayLike): any; 1292 | function defineProperty(target: any, propertyKey: PropertyKey, attributes: PropertyDescriptor): boolean; 1293 | function deleteProperty(target: any, propertyKey: PropertyKey): boolean; 1294 | function enumerate(target: any): IterableIterator; 1295 | function get(target: any, propertyKey: PropertyKey, receiver?: any): any; 1296 | function getOwnPropertyDescriptor(target: any, propertyKey: PropertyKey): PropertyDescriptor; 1297 | function getPrototypeOf(target: any): any; 1298 | function has(target: any, propertyKey: string): boolean; 1299 | function has(target: any, propertyKey: symbol): boolean; 1300 | function isExtensible(target: any): boolean; 1301 | function ownKeys(target: any): Array; 1302 | function preventExtensions(target: any): boolean; 1303 | function set(target: any, propertyKey: PropertyKey, value: any, receiver?: any): boolean; 1304 | function setPrototypeOf(target: any, proto: any): boolean; 1305 | } 1306 | 1307 | var Object: { 1308 | getPrototypeOf(o: any): any; 1309 | getOwnPropertyDescriptor(o: any, p: string): PropertyDescriptor; 1310 | getOwnPropertyNames(o: any): string[]; 1311 | create(o: any, properties?: PropertyDescriptorMap): any; 1312 | defineProperty(o: any, p: string, attributes: PropertyDescriptor): any; 1313 | defineProperties(o: any, properties: PropertyDescriptorMap): any; 1314 | seal(o: T): T; 1315 | freeze(o: T): T; 1316 | preventExtensions(o: T): T; 1317 | isSealed(o: any): boolean; 1318 | isFrozen(o: any): boolean; 1319 | isExtensible(o: any): boolean; 1320 | keys(o: any): string[]; 1321 | assign(target: any, ...sources: any[]): any; 1322 | is(value1: any, value2: any): boolean; 1323 | setPrototypeOf(o: any, proto: any): any; 1324 | getOwnPropertySymbols(o: any): symbol[]; 1325 | getOwnPropertyDescriptor(o: any, propertyKey: PropertyKey): PropertyDescriptor; 1326 | defineProperty(o: any, propertyKey: PropertyKey, attributes: PropertyDescriptor): any; 1327 | values(object: any): any[]; 1328 | entries(object: any): any[]; 1329 | getOwnPropertyDescriptors(object: any): PropertyDescriptorMap; 1330 | isObject(value: any): boolean; 1331 | classof(value: any): string; 1332 | define(target: T, mixin: any): T; 1333 | make(proto: T, mixin?: any): T; 1334 | }; 1335 | 1336 | var Function: { 1337 | bind(target: Function, thisArg: any, ...argArray: any[]): any; 1338 | part(target: Function, ...args: any[]): any; 1339 | }; 1340 | 1341 | var Array: { 1342 | from(arrayLike: ArrayLike, mapfn: (v: T, k: number) => U, thisArg?: any): Array; 1343 | from(iterable: Iterable, mapfn: (v: T, k: number) => U, thisArg?: any): Array; 1344 | from(arrayLike: ArrayLike): Array; 1345 | from(iterable: Iterable): Array; 1346 | of(...items: T[]): Array; 1347 | push(array: ArrayLike, ...items: T[]): number; 1348 | pop(array: ArrayLike): T; 1349 | concat(array: ArrayLike, ...items: (T[]| T)[]): T[]; 1350 | join(array: ArrayLike, separator?: string): string; 1351 | reverse(array: ArrayLike): T[]; 1352 | shift(array: ArrayLike): T; 1353 | slice(array: ArrayLike, start?: number, end?: number): T[]; 1354 | sort(array: ArrayLike, compareFn?: (a: T, b: T) => number): T[]; 1355 | splice(array: ArrayLike, start: number): T[]; 1356 | splice(array: ArrayLike, start: number, deleteCount: number, ...items: T[]): T[]; 1357 | unshift(array: ArrayLike, ...items: T[]): number; 1358 | indexOf(array: ArrayLike, searchElement: T, fromIndex?: number): number; 1359 | lastIndexOf(array: ArrayLike, earchElement: T, fromIndex?: number): number; 1360 | every(array: ArrayLike, callbackfn: (value: T, index: number, array: T[]) => boolean, thisArg?: any): boolean; 1361 | some(array: ArrayLike, callbackfn: (value: T, index: number, array: T[]) => boolean, thisArg?: any): boolean; 1362 | forEach(array: ArrayLike, callbackfn: (value: T, index: number, array: T[]) => void, thisArg?: any): void; 1363 | map(array: ArrayLike, callbackfn: (value: T, index: number, array: T[]) => U, thisArg?: any): U[]; 1364 | filter(array: ArrayLike, callbackfn: (value: T, index: number, array: T[]) => boolean, thisArg?: any): T[]; 1365 | reduce(array: ArrayLike, callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T, initialValue?: T): T; 1366 | reduce(array: ArrayLike, callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: T[]) => U, initialValue: U): U; 1367 | reduceRight(array: ArrayLike, callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T, initialValue?: T): T; 1368 | reduceRight(array: ArrayLike, callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: T[]) => U, initialValue: U): U; 1369 | entries(array: ArrayLike): IterableIterator<[number, T]>; 1370 | keys(array: ArrayLike): IterableIterator; 1371 | values(array: ArrayLike): IterableIterator; 1372 | find(array: ArrayLike, predicate: (value: T, index: number, obj: Array) => boolean, thisArg?: any): T; 1373 | findIndex(array: ArrayLike, predicate: (value: T) => boolean, thisArg?: any): number; 1374 | fill(array: ArrayLike, value: T, start?: number, end?: number): T[]; 1375 | copyWithin(array: ArrayLike, target: number, start: number, end?: number): T[]; 1376 | includes(array: ArrayLike, value: T, fromIndex?: number): boolean; 1377 | turn(array: ArrayLike, callbackfn: (memo: Array, value: T, index: number, array: Array) => void, memo?: Array): Array; 1378 | turn(array: ArrayLike, callbackfn: (memo: U, value: T, index: number, array: Array) => void, memo?: U): U; 1379 | }; 1380 | 1381 | var String: { 1382 | codePointAt(text: string, pos: number): number; 1383 | includes(text: string, searchString: string, position?: number): boolean; 1384 | endsWith(text: string, searchString: string, endPosition?: number): boolean; 1385 | repeat(text: string, count: number): string; 1386 | fromCodePoint(...codePoints: number[]): string; 1387 | raw(template: TemplateStringsArray, ...substitutions: any[]): string; 1388 | startsWith(text: string, searchString: string, position?: number): boolean; 1389 | at(text: string, index: number): string; 1390 | lpad(text: string, length: number, fillStr?: string): string; 1391 | rpad(text: string, length: number, fillStr?: string): string; 1392 | escapeHTML(text: string): string; 1393 | unescapeHTML(text: string): string; 1394 | }; 1395 | 1396 | var Date: { 1397 | now(): number; 1398 | toISOString(date: Date): string; 1399 | format(date: Date, template: string, locale?: string): string; 1400 | formatUTC(date: Date, template: string, locale?: string): string; 1401 | }; 1402 | 1403 | var Number: { 1404 | EPSILON: number; 1405 | isFinite(number: number): boolean; 1406 | isInteger(number: number): boolean; 1407 | isNaN(number: number): boolean; 1408 | isSafeInteger(number: number): boolean; 1409 | MAX_SAFE_INTEGER: number; 1410 | MIN_SAFE_INTEGER: number; 1411 | parseFloat(string: string): number; 1412 | parseInt(string: string, radix?: number): number; 1413 | clz32(x: number): number; 1414 | imul(x: number, y: number): number; 1415 | sign(x: number): number; 1416 | log10(x: number): number; 1417 | log2(x: number): number; 1418 | log1p(x: number): number; 1419 | expm1(x: number): number; 1420 | cosh(x: number): number; 1421 | sinh(x: number): number; 1422 | tanh(x: number): number; 1423 | acosh(x: number): number; 1424 | asinh(x: number): number; 1425 | atanh(x: number): number; 1426 | hypot(...values: number[]): number; 1427 | trunc(x: number): number; 1428 | fround(x: number): number; 1429 | cbrt(x: number): number; 1430 | random(lim?: number): number; 1431 | }; 1432 | 1433 | var Math: { 1434 | clz32(x: number): number; 1435 | imul(x: number, y: number): number; 1436 | sign(x: number): number; 1437 | log10(x: number): number; 1438 | log2(x: number): number; 1439 | log1p(x: number): number; 1440 | expm1(x: number): number; 1441 | cosh(x: number): number; 1442 | sinh(x: number): number; 1443 | tanh(x: number): number; 1444 | acosh(x: number): number; 1445 | asinh(x: number): number; 1446 | atanh(x: number): number; 1447 | hypot(...values: number[]): number; 1448 | trunc(x: number): number; 1449 | fround(x: number): number; 1450 | cbrt(x: number): number; 1451 | }; 1452 | 1453 | var RegExp: { 1454 | escape(str: string): string; 1455 | }; 1456 | 1457 | var Map: MapConstructor; 1458 | var Set: SetConstructor; 1459 | var WeakMap: WeakMapConstructor; 1460 | var WeakSet: WeakSetConstructor; 1461 | var Promise: PromiseConstructor; 1462 | var Symbol: SymbolConstructor; 1463 | var Dict: DictConstructor; 1464 | var global: any; 1465 | var log: Log; 1466 | var _: boolean; 1467 | 1468 | function setTimeout(handler: any, timeout?: any, ...args: any[]): number; 1469 | 1470 | function setInterval(handler: any, timeout?: any, ...args: any[]): number; 1471 | 1472 | function setImmediate(expression: any, ...args: any[]): number; 1473 | 1474 | function clearImmediate(handle: number): void; 1475 | 1476 | function $for(iterable: Iterable): $for; 1477 | 1478 | function isIterable(value: any): boolean; 1479 | 1480 | function getIterator(iterable: Iterable): Iterator; 1481 | 1482 | interface Locale { 1483 | weekdays: string; 1484 | months: string; 1485 | } 1486 | 1487 | function addLocale(lang: string, locale: Locale): typeof core; 1488 | 1489 | function locale(lang?: string): string; 1490 | 1491 | function delay(msec: number): Promise; 1492 | } 1493 | 1494 | declare module "core-js" { 1495 | export = core; 1496 | } 1497 | declare module "core-js/shim" { 1498 | export = core; 1499 | } 1500 | declare module "core-js/core" { 1501 | export = core; 1502 | } 1503 | declare module "core-js/core/$for" { 1504 | import $for = core.$for; 1505 | export = $for; 1506 | } 1507 | declare module "core-js/core/_" { 1508 | var _: typeof core._; 1509 | export = _; 1510 | } 1511 | declare module "core-js/core/array" { 1512 | var Array: typeof core.Array; 1513 | export = Array; 1514 | } 1515 | declare module "core-js/core/date" { 1516 | var Date: typeof core.Date; 1517 | export = Date; 1518 | } 1519 | declare module "core-js/core/delay" { 1520 | var delay: typeof core.delay; 1521 | export = delay; 1522 | } 1523 | declare module "core-js/core/dict" { 1524 | var Dict: typeof core.Dict; 1525 | export = Dict; 1526 | } 1527 | declare module "core-js/core/function" { 1528 | var Function: typeof core.Function; 1529 | export = Function; 1530 | } 1531 | declare module "core-js/core/global" { 1532 | var global: typeof core.global; 1533 | export = global; 1534 | } 1535 | declare module "core-js/core/log" { 1536 | var log: typeof core.log; 1537 | export = log; 1538 | } 1539 | declare module "core-js/core/number" { 1540 | var Number: typeof core.Number; 1541 | export = Number; 1542 | } 1543 | declare module "core-js/core/object" { 1544 | var Object: typeof core.Object; 1545 | export = Object; 1546 | } 1547 | declare module "core-js/core/string" { 1548 | var String: typeof core.String; 1549 | export = String; 1550 | } 1551 | declare module "core-js/fn/$for" { 1552 | import $for = core.$for; 1553 | export = $for; 1554 | } 1555 | declare module "core-js/fn/_" { 1556 | var _: typeof core._; 1557 | export = _; 1558 | } 1559 | declare module "core-js/fn/clear-immediate" { 1560 | var clearImmediate: typeof core.clearImmediate; 1561 | export = clearImmediate; 1562 | } 1563 | declare module "core-js/fn/delay" { 1564 | var delay: typeof core.delay; 1565 | export = delay; 1566 | } 1567 | declare module "core-js/fn/dict" { 1568 | var Dict: typeof core.Dict; 1569 | export = Dict; 1570 | } 1571 | declare module "core-js/fn/get-iterator" { 1572 | var getIterator: typeof core.getIterator; 1573 | export = getIterator; 1574 | } 1575 | declare module "core-js/fn/global" { 1576 | var global: typeof core.global; 1577 | export = global; 1578 | } 1579 | declare module "core-js/fn/is-iterable" { 1580 | var isIterable: typeof core.isIterable; 1581 | export = isIterable; 1582 | } 1583 | declare module "core-js/fn/log" { 1584 | var log: typeof core.log; 1585 | export = log; 1586 | } 1587 | declare module "core-js/fn/map" { 1588 | var Map: typeof core.Map; 1589 | export = Map; 1590 | } 1591 | declare module "core-js/fn/promise" { 1592 | var Promise: typeof core.Promise; 1593 | export = Promise; 1594 | } 1595 | declare module "core-js/fn/set" { 1596 | var Set: typeof core.Set; 1597 | export = Set; 1598 | } 1599 | declare module "core-js/fn/set-immediate" { 1600 | var setImmediate: typeof core.setImmediate; 1601 | export = setImmediate; 1602 | } 1603 | declare module "core-js/fn/set-interval" { 1604 | var setInterval: typeof core.setInterval; 1605 | export = setInterval; 1606 | } 1607 | declare module "core-js/fn/set-timeout" { 1608 | var setTimeout: typeof core.setTimeout; 1609 | export = setTimeout; 1610 | } 1611 | declare module "core-js/fn/weak-map" { 1612 | var WeakMap: typeof core.WeakMap; 1613 | export = WeakMap; 1614 | } 1615 | declare module "core-js/fn/weak-set" { 1616 | var WeakSet: typeof core.WeakSet; 1617 | export = WeakSet; 1618 | } 1619 | declare module "core-js/fn/array" { 1620 | var Array: typeof core.Array; 1621 | export = Array; 1622 | } 1623 | declare module "core-js/fn/array/concat" { 1624 | var concat: typeof core.Array.concat; 1625 | export = concat; 1626 | } 1627 | declare module "core-js/fn/array/copy-within" { 1628 | var copyWithin: typeof core.Array.copyWithin; 1629 | export = copyWithin; 1630 | } 1631 | declare module "core-js/fn/array/entries" { 1632 | var entries: typeof core.Array.entries; 1633 | export = entries; 1634 | } 1635 | declare module "core-js/fn/array/every" { 1636 | var every: typeof core.Array.every; 1637 | export = every; 1638 | } 1639 | declare module "core-js/fn/array/fill" { 1640 | var fill: typeof core.Array.fill; 1641 | export = fill; 1642 | } 1643 | declare module "core-js/fn/array/filter" { 1644 | var filter: typeof core.Array.filter; 1645 | export = filter; 1646 | } 1647 | declare module "core-js/fn/array/find" { 1648 | var find: typeof core.Array.find; 1649 | export = find; 1650 | } 1651 | declare module "core-js/fn/array/find-index" { 1652 | var findIndex: typeof core.Array.findIndex; 1653 | export = findIndex; 1654 | } 1655 | declare module "core-js/fn/array/for-each" { 1656 | var forEach: typeof core.Array.forEach; 1657 | export = forEach; 1658 | } 1659 | declare module "core-js/fn/array/from" { 1660 | var from: typeof core.Array.from; 1661 | export = from; 1662 | } 1663 | declare module "core-js/fn/array/includes" { 1664 | var includes: typeof core.Array.includes; 1665 | export = includes; 1666 | } 1667 | declare module "core-js/fn/array/index-of" { 1668 | var indexOf: typeof core.Array.indexOf; 1669 | export = indexOf; 1670 | } 1671 | declare module "core-js/fn/array/join" { 1672 | var join: typeof core.Array.join; 1673 | export = join; 1674 | } 1675 | declare module "core-js/fn/array/keys" { 1676 | var keys: typeof core.Array.keys; 1677 | export = keys; 1678 | } 1679 | declare module "core-js/fn/array/last-index-of" { 1680 | var lastIndexOf: typeof core.Array.lastIndexOf; 1681 | export = lastIndexOf; 1682 | } 1683 | declare module "core-js/fn/array/map" { 1684 | var map: typeof core.Array.map; 1685 | export = map; 1686 | } 1687 | declare module "core-js/fn/array/of" { 1688 | var of: typeof core.Array.of; 1689 | export = of; 1690 | } 1691 | declare module "core-js/fn/array/pop" { 1692 | var pop: typeof core.Array.pop; 1693 | export = pop; 1694 | } 1695 | declare module "core-js/fn/array/push" { 1696 | var push: typeof core.Array.push; 1697 | export = push; 1698 | } 1699 | declare module "core-js/fn/array/reduce" { 1700 | var reduce: typeof core.Array.reduce; 1701 | export = reduce; 1702 | } 1703 | declare module "core-js/fn/array/reduce-right" { 1704 | var reduceRight: typeof core.Array.reduceRight; 1705 | export = reduceRight; 1706 | } 1707 | declare module "core-js/fn/array/reverse" { 1708 | var reverse: typeof core.Array.reverse; 1709 | export = reverse; 1710 | } 1711 | declare module "core-js/fn/array/shift" { 1712 | var shift: typeof core.Array.shift; 1713 | export = shift; 1714 | } 1715 | declare module "core-js/fn/array/slice" { 1716 | var slice: typeof core.Array.slice; 1717 | export = slice; 1718 | } 1719 | declare module "core-js/fn/array/some" { 1720 | var some: typeof core.Array.some; 1721 | export = some; 1722 | } 1723 | declare module "core-js/fn/array/sort" { 1724 | var sort: typeof core.Array.sort; 1725 | export = sort; 1726 | } 1727 | declare module "core-js/fn/array/splice" { 1728 | var splice: typeof core.Array.splice; 1729 | export = splice; 1730 | } 1731 | declare module "core-js/fn/array/turn" { 1732 | var turn: typeof core.Array.turn; 1733 | export = turn; 1734 | } 1735 | declare module "core-js/fn/array/unshift" { 1736 | var unshift: typeof core.Array.unshift; 1737 | export = unshift; 1738 | } 1739 | declare module "core-js/fn/array/values" { 1740 | var values: typeof core.Array.values; 1741 | export = values; 1742 | } 1743 | declare module "core-js/fn/date" { 1744 | var Date: typeof core.Date; 1745 | export = Date; 1746 | } 1747 | declare module "core-js/fn/date/add-locale" { 1748 | var addLocale: typeof core.addLocale; 1749 | export = addLocale; 1750 | } 1751 | declare module "core-js/fn/date/format" { 1752 | var format: typeof core.Date.format; 1753 | export = format; 1754 | } 1755 | declare module "core-js/fn/date/formatUTC" { 1756 | var formatUTC: typeof core.Date.formatUTC; 1757 | export = formatUTC; 1758 | } 1759 | declare module "core-js/fn/function" { 1760 | var Function: typeof core.Function; 1761 | export = Function; 1762 | } 1763 | declare module "core-js/fn/function/has-instance" { 1764 | var hasInstance: (value: any) => boolean; 1765 | export = hasInstance; 1766 | } 1767 | declare module "core-js/fn/function/name" 1768 | { 1769 | } 1770 | declare module "core-js/fn/function/part" { 1771 | var part: typeof core.Function.part; 1772 | export = part; 1773 | } 1774 | declare module "core-js/fn/math" { 1775 | var Math: typeof core.Math; 1776 | export = Math; 1777 | } 1778 | declare module "core-js/fn/math/acosh" { 1779 | var acosh: typeof core.Math.acosh; 1780 | export = acosh; 1781 | } 1782 | declare module "core-js/fn/math/asinh" { 1783 | var asinh: typeof core.Math.asinh; 1784 | export = asinh; 1785 | } 1786 | declare module "core-js/fn/math/atanh" { 1787 | var atanh: typeof core.Math.atanh; 1788 | export = atanh; 1789 | } 1790 | declare module "core-js/fn/math/cbrt" { 1791 | var cbrt: typeof core.Math.cbrt; 1792 | export = cbrt; 1793 | } 1794 | declare module "core-js/fn/math/clz32" { 1795 | var clz32: typeof core.Math.clz32; 1796 | export = clz32; 1797 | } 1798 | declare module "core-js/fn/math/cosh" { 1799 | var cosh: typeof core.Math.cosh; 1800 | export = cosh; 1801 | } 1802 | declare module "core-js/fn/math/expm1" { 1803 | var expm1: typeof core.Math.expm1; 1804 | export = expm1; 1805 | } 1806 | declare module "core-js/fn/math/fround" { 1807 | var fround: typeof core.Math.fround; 1808 | export = fround; 1809 | } 1810 | declare module "core-js/fn/math/hypot" { 1811 | var hypot: typeof core.Math.hypot; 1812 | export = hypot; 1813 | } 1814 | declare module "core-js/fn/math/imul" { 1815 | var imul: typeof core.Math.imul; 1816 | export = imul; 1817 | } 1818 | declare module "core-js/fn/math/log10" { 1819 | var log10: typeof core.Math.log10; 1820 | export = log10; 1821 | } 1822 | declare module "core-js/fn/math/log1p" { 1823 | var log1p: typeof core.Math.log1p; 1824 | export = log1p; 1825 | } 1826 | declare module "core-js/fn/math/log2" { 1827 | var log2: typeof core.Math.log2; 1828 | export = log2; 1829 | } 1830 | declare module "core-js/fn/math/sign" { 1831 | var sign: typeof core.Math.sign; 1832 | export = sign; 1833 | } 1834 | declare module "core-js/fn/math/sinh" { 1835 | var sinh: typeof core.Math.sinh; 1836 | export = sinh; 1837 | } 1838 | declare module "core-js/fn/math/tanh" { 1839 | var tanh: typeof core.Math.tanh; 1840 | export = tanh; 1841 | } 1842 | declare module "core-js/fn/math/trunc" { 1843 | var trunc: typeof core.Math.trunc; 1844 | export = trunc; 1845 | } 1846 | declare module "core-js/fn/number" { 1847 | var Number: typeof core.Number; 1848 | export = Number; 1849 | } 1850 | declare module "core-js/fn/number/epsilon" { 1851 | var EPSILON: typeof core.Number.EPSILON; 1852 | export = EPSILON; 1853 | } 1854 | declare module "core-js/fn/number/is-finite" { 1855 | var isFinite: typeof core.Number.isFinite; 1856 | export = isFinite; 1857 | } 1858 | declare module "core-js/fn/number/is-integer" { 1859 | var isInteger: typeof core.Number.isInteger; 1860 | export = isInteger; 1861 | } 1862 | declare module "core-js/fn/number/is-nan" { 1863 | var isNaN: typeof core.Number.isNaN; 1864 | export = isNaN; 1865 | } 1866 | declare module "core-js/fn/number/is-safe-integer" { 1867 | var isSafeInteger: typeof core.Number.isSafeInteger; 1868 | export = isSafeInteger; 1869 | } 1870 | declare module "core-js/fn/number/max-safe-integer" { 1871 | var MAX_SAFE_INTEGER: typeof core.Number.MAX_SAFE_INTEGER; 1872 | export = MAX_SAFE_INTEGER; 1873 | } 1874 | declare module "core-js/fn/number/min-safe-interger" { 1875 | var MIN_SAFE_INTEGER: typeof core.Number.MIN_SAFE_INTEGER; 1876 | export = MIN_SAFE_INTEGER; 1877 | } 1878 | declare module "core-js/fn/number/parse-float" { 1879 | var parseFloat: typeof core.Number.parseFloat; 1880 | export = parseFloat; 1881 | } 1882 | declare module "core-js/fn/number/parse-int" { 1883 | var parseInt: typeof core.Number.parseInt; 1884 | export = parseInt; 1885 | } 1886 | declare module "core-js/fn/number/random" { 1887 | var random: typeof core.Number.random; 1888 | export = random; 1889 | } 1890 | declare module "core-js/fn/object" { 1891 | var Object: typeof core.Object; 1892 | export = Object; 1893 | } 1894 | declare module "core-js/fn/object/assign" { 1895 | var assign: typeof core.Object.assign; 1896 | export = assign; 1897 | } 1898 | declare module "core-js/fn/object/classof" { 1899 | var classof: typeof core.Object.classof; 1900 | export = classof; 1901 | } 1902 | declare module "core-js/fn/object/create" { 1903 | var create: typeof core.Object.create; 1904 | export = create; 1905 | } 1906 | declare module "core-js/fn/object/define" { 1907 | var define: typeof core.Object.define; 1908 | export = define; 1909 | } 1910 | declare module "core-js/fn/object/define-properties" { 1911 | var defineProperties: typeof core.Object.defineProperties; 1912 | export = defineProperties; 1913 | } 1914 | declare module "core-js/fn/object/define-property" { 1915 | var defineProperty: typeof core.Object.defineProperty; 1916 | export = defineProperty; 1917 | } 1918 | declare module "core-js/fn/object/entries" { 1919 | var entries: typeof core.Object.entries; 1920 | export = entries; 1921 | } 1922 | declare module "core-js/fn/object/freeze" { 1923 | var freeze: typeof core.Object.freeze; 1924 | export = freeze; 1925 | } 1926 | declare module "core-js/fn/object/get-own-property-descriptor" { 1927 | var getOwnPropertyDescriptor: typeof core.Object.getOwnPropertyDescriptor; 1928 | export = getOwnPropertyDescriptor; 1929 | } 1930 | declare module "core-js/fn/object/get-own-property-descriptors" { 1931 | var getOwnPropertyDescriptors: typeof core.Object.getOwnPropertyDescriptors; 1932 | export = getOwnPropertyDescriptors; 1933 | } 1934 | declare module "core-js/fn/object/get-own-property-names" { 1935 | var getOwnPropertyNames: typeof core.Object.getOwnPropertyNames; 1936 | export = getOwnPropertyNames; 1937 | } 1938 | declare module "core-js/fn/object/get-own-property-symbols" { 1939 | var getOwnPropertySymbols: typeof core.Object.getOwnPropertySymbols; 1940 | export = getOwnPropertySymbols; 1941 | } 1942 | declare module "core-js/fn/object/get-prototype-of" { 1943 | var getPrototypeOf: typeof core.Object.getPrototypeOf; 1944 | export = getPrototypeOf; 1945 | } 1946 | declare module "core-js/fn/object/is" { 1947 | var is: typeof core.Object.is; 1948 | export = is; 1949 | } 1950 | declare module "core-js/fn/object/is-extensible" { 1951 | var isExtensible: typeof core.Object.isExtensible; 1952 | export = isExtensible; 1953 | } 1954 | declare module "core-js/fn/object/is-frozen" { 1955 | var isFrozen: typeof core.Object.isFrozen; 1956 | export = isFrozen; 1957 | } 1958 | declare module "core-js/fn/object/is-object" { 1959 | var isObject: typeof core.Object.isObject; 1960 | export = isObject; 1961 | } 1962 | declare module "core-js/fn/object/is-sealed" { 1963 | var isSealed: typeof core.Object.isSealed; 1964 | export = isSealed; 1965 | } 1966 | declare module "core-js/fn/object/keys" { 1967 | var keys: typeof core.Object.keys; 1968 | export = keys; 1969 | } 1970 | declare module "core-js/fn/object/make" { 1971 | var make: typeof core.Object.make; 1972 | export = make; 1973 | } 1974 | declare module "core-js/fn/object/prevent-extensions" { 1975 | var preventExtensions: typeof core.Object.preventExtensions; 1976 | export = preventExtensions; 1977 | } 1978 | declare module "core-js/fn/object/seal" { 1979 | var seal: typeof core.Object.seal; 1980 | export = seal; 1981 | } 1982 | declare module "core-js/fn/object/set-prototype-of" { 1983 | var setPrototypeOf: typeof core.Object.setPrototypeOf; 1984 | export = setPrototypeOf; 1985 | } 1986 | declare module "core-js/fn/object/values" { 1987 | var values: typeof core.Object.values; 1988 | export = values; 1989 | } 1990 | declare module "core-js/fn/reflect" { 1991 | var Reflect: typeof core.Reflect; 1992 | export = Reflect; 1993 | } 1994 | declare module "core-js/fn/reflect/apply" { 1995 | var apply: typeof core.Reflect.apply; 1996 | export = apply; 1997 | } 1998 | declare module "core-js/fn/reflect/construct" { 1999 | var construct: typeof core.Reflect.construct; 2000 | export = construct; 2001 | } 2002 | declare module "core-js/fn/reflect/define-property" { 2003 | var defineProperty: typeof core.Reflect.defineProperty; 2004 | export = defineProperty; 2005 | } 2006 | declare module "core-js/fn/reflect/delete-property" { 2007 | var deleteProperty: typeof core.Reflect.deleteProperty; 2008 | export = deleteProperty; 2009 | } 2010 | declare module "core-js/fn/reflect/enumerate" { 2011 | var enumerate: typeof core.Reflect.enumerate; 2012 | export = enumerate; 2013 | } 2014 | declare module "core-js/fn/reflect/get" { 2015 | var get: typeof core.Reflect.get; 2016 | export = get; 2017 | } 2018 | declare module "core-js/fn/reflect/get-own-property-descriptor" { 2019 | var getOwnPropertyDescriptor: typeof core.Reflect.getOwnPropertyDescriptor; 2020 | export = getOwnPropertyDescriptor; 2021 | } 2022 | declare module "core-js/fn/reflect/get-prototype-of" { 2023 | var getPrototypeOf: typeof core.Reflect.getPrototypeOf; 2024 | export = getPrototypeOf; 2025 | } 2026 | declare module "core-js/fn/reflect/has" { 2027 | var has: typeof core.Reflect.has; 2028 | export = has; 2029 | } 2030 | declare module "core-js/fn/reflect/is-extensible" { 2031 | var isExtensible: typeof core.Reflect.isExtensible; 2032 | export = isExtensible; 2033 | } 2034 | declare module "core-js/fn/reflect/own-keys" { 2035 | var ownKeys: typeof core.Reflect.ownKeys; 2036 | export = ownKeys; 2037 | } 2038 | declare module "core-js/fn/reflect/prevent-extensions" { 2039 | var preventExtensions: typeof core.Reflect.preventExtensions; 2040 | export = preventExtensions; 2041 | } 2042 | declare module "core-js/fn/reflect/set" { 2043 | var set: typeof core.Reflect.set; 2044 | export = set; 2045 | } 2046 | declare module "core-js/fn/reflect/set-prototype-of" { 2047 | var setPrototypeOf: typeof core.Reflect.setPrototypeOf; 2048 | export = setPrototypeOf; 2049 | } 2050 | declare module "core-js/fn/regexp" { 2051 | var RegExp: typeof core.RegExp; 2052 | export = RegExp; 2053 | } 2054 | declare module "core-js/fn/regexp/escape" { 2055 | var escape: typeof core.RegExp.escape; 2056 | export = escape; 2057 | } 2058 | declare module "core-js/fn/string" { 2059 | var String: typeof core.String; 2060 | export = String; 2061 | } 2062 | declare module "core-js/fn/string/at" { 2063 | var at: typeof core.String.at; 2064 | export = at; 2065 | } 2066 | declare module "core-js/fn/string/code-point-at" { 2067 | var codePointAt: typeof core.String.codePointAt; 2068 | export = codePointAt; 2069 | } 2070 | declare module "core-js/fn/string/ends-with" { 2071 | var endsWith: typeof core.String.endsWith; 2072 | export = endsWith; 2073 | } 2074 | declare module "core-js/fn/string/escape-html" { 2075 | var escapeHTML: typeof core.String.escapeHTML; 2076 | export = escapeHTML; 2077 | } 2078 | declare module "core-js/fn/string/from-code-point" { 2079 | var fromCodePoint: typeof core.String.fromCodePoint; 2080 | export = fromCodePoint; 2081 | } 2082 | declare module "core-js/fn/string/includes" { 2083 | var includes: typeof core.String.includes; 2084 | export = includes; 2085 | } 2086 | declare module "core-js/fn/string/lpad" { 2087 | var lpad: typeof core.String.lpad; 2088 | export = lpad; 2089 | } 2090 | declare module "core-js/fn/string/raw" { 2091 | var raw: typeof core.String.raw; 2092 | export = raw; 2093 | } 2094 | declare module "core-js/fn/string/repeat" { 2095 | var repeat: typeof core.String.repeat; 2096 | export = repeat; 2097 | } 2098 | declare module "core-js/fn/string/rpad" { 2099 | var rpad: typeof core.String.rpad; 2100 | export = rpad; 2101 | } 2102 | declare module "core-js/fn/string/starts-with" { 2103 | var startsWith: typeof core.String.startsWith; 2104 | export = startsWith; 2105 | } 2106 | declare module "core-js/fn/string/unescape-html" { 2107 | var unescapeHTML: typeof core.String.unescapeHTML; 2108 | export = unescapeHTML; 2109 | } 2110 | declare module "core-js/fn/symbol" { 2111 | var Symbol: typeof core.Symbol; 2112 | export = Symbol; 2113 | } 2114 | declare module "core-js/fn/symbol/for" { 2115 | var _for: typeof core.Symbol.for; 2116 | export = _for; 2117 | } 2118 | declare module "core-js/fn/symbol/has-instance" { 2119 | var hasInstance: typeof core.Symbol.hasInstance; 2120 | export = hasInstance; 2121 | } 2122 | declare module "core-js/fn/symbol/is-concat-spreadable" { 2123 | var isConcatSpreadable: typeof core.Symbol.isConcatSpreadable; 2124 | export = isConcatSpreadable; 2125 | } 2126 | declare module "core-js/fn/symbol/iterator" { 2127 | var iterator: typeof core.Symbol.iterator; 2128 | export = iterator; 2129 | } 2130 | declare module "core-js/fn/symbol/key-for" { 2131 | var keyFor: typeof core.Symbol.keyFor; 2132 | export = keyFor; 2133 | } 2134 | declare module "core-js/fn/symbol/match" { 2135 | var match: typeof core.Symbol.match; 2136 | export = match; 2137 | } 2138 | declare module "core-js/fn/symbol/replace" { 2139 | var replace: typeof core.Symbol.replace; 2140 | export = replace; 2141 | } 2142 | declare module "core-js/fn/symbol/search" { 2143 | var search: typeof core.Symbol.search; 2144 | export = search; 2145 | } 2146 | declare module "core-js/fn/symbol/species" { 2147 | var species: typeof core.Symbol.species; 2148 | export = species; 2149 | } 2150 | declare module "core-js/fn/symbol/split" { 2151 | var split: typeof core.Symbol.split; 2152 | export = split; 2153 | } 2154 | declare module "core-js/fn/symbol/to-primitive" { 2155 | var toPrimitive: typeof core.Symbol.toPrimitive; 2156 | export = toPrimitive; 2157 | } 2158 | declare module "core-js/fn/symbol/to-string-tag" { 2159 | var toStringTag: typeof core.Symbol.toStringTag; 2160 | export = toStringTag; 2161 | } 2162 | declare module "core-js/fn/symbol/unscopables" { 2163 | var unscopables: typeof core.Symbol.unscopables; 2164 | export = unscopables; 2165 | } 2166 | declare module "core-js/es5" { 2167 | export = core; 2168 | } 2169 | declare module "core-js/es6" { 2170 | export = core; 2171 | } 2172 | declare module "core-js/es6/array" { 2173 | var Array: typeof core.Array; 2174 | export = Array; 2175 | } 2176 | declare module "core-js/es6/function" { 2177 | var Function: typeof core.Function; 2178 | export = Function; 2179 | } 2180 | declare module "core-js/es6/map" { 2181 | var Map: typeof core.Map; 2182 | export = Map; 2183 | } 2184 | declare module "core-js/es6/math" { 2185 | var Math: typeof core.Math; 2186 | export = Math; 2187 | } 2188 | declare module "core-js/es6/number" { 2189 | var Number: typeof core.Number; 2190 | export = Number; 2191 | } 2192 | declare module "core-js/es6/object" { 2193 | var Object: typeof core.Object; 2194 | export = Object; 2195 | } 2196 | declare module "core-js/es6/promise" { 2197 | var Promise: typeof core.Promise; 2198 | export = Promise; 2199 | } 2200 | declare module "core-js/es6/reflect" { 2201 | var Reflect: typeof core.Reflect; 2202 | export = Reflect; 2203 | } 2204 | declare module "core-js/es6/regexp" { 2205 | var RegExp: typeof core.RegExp; 2206 | export = RegExp; 2207 | } 2208 | declare module "core-js/es6/set" { 2209 | var Set: typeof core.Set; 2210 | export = Set; 2211 | } 2212 | declare module "core-js/es6/string" { 2213 | var String: typeof core.String; 2214 | export = String; 2215 | } 2216 | declare module "core-js/es6/symbol" { 2217 | var Symbol: typeof core.Symbol; 2218 | export = Symbol; 2219 | } 2220 | declare module "core-js/es6/weak-map" { 2221 | var WeakMap: typeof core.WeakMap; 2222 | export = WeakMap; 2223 | } 2224 | declare module "core-js/es6/weak-set" { 2225 | var WeakSet: typeof core.WeakSet; 2226 | export = WeakSet; 2227 | } 2228 | declare module "core-js/es7" { 2229 | export = core; 2230 | } 2231 | declare module "core-js/es7/array" { 2232 | var Array: typeof core.Array; 2233 | export = Array; 2234 | } 2235 | declare module "core-js/es7/map" { 2236 | var Map: typeof core.Map; 2237 | export = Map; 2238 | } 2239 | declare module "core-js/es7/object" { 2240 | var Object: typeof core.Object; 2241 | export = Object; 2242 | } 2243 | declare module "core-js/es7/regexp" { 2244 | var RegExp: typeof core.RegExp; 2245 | export = RegExp; 2246 | } 2247 | declare module "core-js/es7/set" { 2248 | var Set: typeof core.Set; 2249 | export = Set; 2250 | } 2251 | declare module "core-js/es7/string" { 2252 | var String: typeof core.String; 2253 | export = String; 2254 | } 2255 | declare module "core-js/js" { 2256 | export = core; 2257 | } 2258 | declare module "core-js/js/array" { 2259 | var Array: typeof core.Array; 2260 | export = Array; 2261 | } 2262 | declare module "core-js/web" { 2263 | export = core; 2264 | } 2265 | declare module "core-js/web/dom" { 2266 | export = core; 2267 | } 2268 | declare module "core-js/web/immediate" { 2269 | export = core; 2270 | } 2271 | declare module "core-js/web/timers" { 2272 | export = core; 2273 | } 2274 | declare module "core-js/library" { 2275 | export = core; 2276 | } 2277 | declare module "core-js/library/shim" { 2278 | export = core; 2279 | } 2280 | declare module "core-js/library/core" { 2281 | export = core; 2282 | } 2283 | declare module "core-js/library/core/$for" { 2284 | import $for = core.$for; 2285 | export = $for; 2286 | } 2287 | declare module "core-js/library/core/_" { 2288 | var _: typeof core._; 2289 | export = _; 2290 | } 2291 | declare module "core-js/library/core/array" { 2292 | var Array: typeof core.Array; 2293 | export = Array; 2294 | } 2295 | declare module "core-js/library/core/date" { 2296 | var Date: typeof core.Date; 2297 | export = Date; 2298 | } 2299 | declare module "core-js/library/core/delay" { 2300 | var delay: typeof core.delay; 2301 | export = delay; 2302 | } 2303 | declare module "core-js/library/core/dict" { 2304 | var Dict: typeof core.Dict; 2305 | export = Dict; 2306 | } 2307 | declare module "core-js/library/core/function" { 2308 | var Function: typeof core.Function; 2309 | export = Function; 2310 | } 2311 | declare module "core-js/library/core/global" { 2312 | var global: typeof core.global; 2313 | export = global; 2314 | } 2315 | declare module "core-js/library/core/log" { 2316 | var log: typeof core.log; 2317 | export = log; 2318 | } 2319 | declare module "core-js/library/core/number" { 2320 | var Number: typeof core.Number; 2321 | export = Number; 2322 | } 2323 | declare module "core-js/library/core/object" { 2324 | var Object: typeof core.Object; 2325 | export = Object; 2326 | } 2327 | declare module "core-js/library/core/string" { 2328 | var String: typeof core.String; 2329 | export = String; 2330 | } 2331 | declare module "core-js/library/fn/$for" { 2332 | import $for = core.$for; 2333 | export = $for; 2334 | } 2335 | declare module "core-js/library/fn/_" { 2336 | var _: typeof core._; 2337 | export = _; 2338 | } 2339 | declare module "core-js/library/fn/clear-immediate" { 2340 | var clearImmediate: typeof core.clearImmediate; 2341 | export = clearImmediate; 2342 | } 2343 | declare module "core-js/library/fn/delay" { 2344 | var delay: typeof core.delay; 2345 | export = delay; 2346 | } 2347 | declare module "core-js/library/fn/dict" { 2348 | var Dict: typeof core.Dict; 2349 | export = Dict; 2350 | } 2351 | declare module "core-js/library/fn/get-iterator" { 2352 | var getIterator: typeof core.getIterator; 2353 | export = getIterator; 2354 | } 2355 | declare module "core-js/library/fn/global" { 2356 | var global: typeof core.global; 2357 | export = global; 2358 | } 2359 | declare module "core-js/library/fn/is-iterable" { 2360 | var isIterable: typeof core.isIterable; 2361 | export = isIterable; 2362 | } 2363 | declare module "core-js/library/fn/log" { 2364 | var log: typeof core.log; 2365 | export = log; 2366 | } 2367 | declare module "core-js/library/fn/map" { 2368 | var Map: typeof core.Map; 2369 | export = Map; 2370 | } 2371 | declare module "core-js/library/fn/promise" { 2372 | var Promise: typeof core.Promise; 2373 | export = Promise; 2374 | } 2375 | declare module "core-js/library/fn/set" { 2376 | var Set: typeof core.Set; 2377 | export = Set; 2378 | } 2379 | declare module "core-js/library/fn/set-immediate" { 2380 | var setImmediate: typeof core.setImmediate; 2381 | export = setImmediate; 2382 | } 2383 | declare module "core-js/library/fn/set-interval" { 2384 | var setInterval: typeof core.setInterval; 2385 | export = setInterval; 2386 | } 2387 | declare module "core-js/library/fn/set-timeout" { 2388 | var setTimeout: typeof core.setTimeout; 2389 | export = setTimeout; 2390 | } 2391 | declare module "core-js/library/fn/weak-map" { 2392 | var WeakMap: typeof core.WeakMap; 2393 | export = WeakMap; 2394 | } 2395 | declare module "core-js/library/fn/weak-set" { 2396 | var WeakSet: typeof core.WeakSet; 2397 | export = WeakSet; 2398 | } 2399 | declare module "core-js/library/fn/array" { 2400 | var Array: typeof core.Array; 2401 | export = Array; 2402 | } 2403 | declare module "core-js/library/fn/array/concat" { 2404 | var concat: typeof core.Array.concat; 2405 | export = concat; 2406 | } 2407 | declare module "core-js/library/fn/array/copy-within" { 2408 | var copyWithin: typeof core.Array.copyWithin; 2409 | export = copyWithin; 2410 | } 2411 | declare module "core-js/library/fn/array/entries" { 2412 | var entries: typeof core.Array.entries; 2413 | export = entries; 2414 | } 2415 | declare module "core-js/library/fn/array/every" { 2416 | var every: typeof core.Array.every; 2417 | export = every; 2418 | } 2419 | declare module "core-js/library/fn/array/fill" { 2420 | var fill: typeof core.Array.fill; 2421 | export = fill; 2422 | } 2423 | declare module "core-js/library/fn/array/filter" { 2424 | var filter: typeof core.Array.filter; 2425 | export = filter; 2426 | } 2427 | declare module "core-js/library/fn/array/find" { 2428 | var find: typeof core.Array.find; 2429 | export = find; 2430 | } 2431 | declare module "core-js/library/fn/array/find-index" { 2432 | var findIndex: typeof core.Array.findIndex; 2433 | export = findIndex; 2434 | } 2435 | declare module "core-js/library/fn/array/for-each" { 2436 | var forEach: typeof core.Array.forEach; 2437 | export = forEach; 2438 | } 2439 | declare module "core-js/library/fn/array/from" { 2440 | var from: typeof core.Array.from; 2441 | export = from; 2442 | } 2443 | declare module "core-js/library/fn/array/includes" { 2444 | var includes: typeof core.Array.includes; 2445 | export = includes; 2446 | } 2447 | declare module "core-js/library/fn/array/index-of" { 2448 | var indexOf: typeof core.Array.indexOf; 2449 | export = indexOf; 2450 | } 2451 | declare module "core-js/library/fn/array/join" { 2452 | var join: typeof core.Array.join; 2453 | export = join; 2454 | } 2455 | declare module "core-js/library/fn/array/keys" { 2456 | var keys: typeof core.Array.keys; 2457 | export = keys; 2458 | } 2459 | declare module "core-js/library/fn/array/last-index-of" { 2460 | var lastIndexOf: typeof core.Array.lastIndexOf; 2461 | export = lastIndexOf; 2462 | } 2463 | declare module "core-js/library/fn/array/map" { 2464 | var map: typeof core.Array.map; 2465 | export = map; 2466 | } 2467 | declare module "core-js/library/fn/array/of" { 2468 | var of: typeof core.Array.of; 2469 | export = of; 2470 | } 2471 | declare module "core-js/library/fn/array/pop" { 2472 | var pop: typeof core.Array.pop; 2473 | export = pop; 2474 | } 2475 | declare module "core-js/library/fn/array/push" { 2476 | var push: typeof core.Array.push; 2477 | export = push; 2478 | } 2479 | declare module "core-js/library/fn/array/reduce" { 2480 | var reduce: typeof core.Array.reduce; 2481 | export = reduce; 2482 | } 2483 | declare module "core-js/library/fn/array/reduce-right" { 2484 | var reduceRight: typeof core.Array.reduceRight; 2485 | export = reduceRight; 2486 | } 2487 | declare module "core-js/library/fn/array/reverse" { 2488 | var reverse: typeof core.Array.reverse; 2489 | export = reverse; 2490 | } 2491 | declare module "core-js/library/fn/array/shift" { 2492 | var shift: typeof core.Array.shift; 2493 | export = shift; 2494 | } 2495 | declare module "core-js/library/fn/array/slice" { 2496 | var slice: typeof core.Array.slice; 2497 | export = slice; 2498 | } 2499 | declare module "core-js/library/fn/array/some" { 2500 | var some: typeof core.Array.some; 2501 | export = some; 2502 | } 2503 | declare module "core-js/library/fn/array/sort" { 2504 | var sort: typeof core.Array.sort; 2505 | export = sort; 2506 | } 2507 | declare module "core-js/library/fn/array/splice" { 2508 | var splice: typeof core.Array.splice; 2509 | export = splice; 2510 | } 2511 | declare module "core-js/library/fn/array/turn" { 2512 | var turn: typeof core.Array.turn; 2513 | export = turn; 2514 | } 2515 | declare module "core-js/library/fn/array/unshift" { 2516 | var unshift: typeof core.Array.unshift; 2517 | export = unshift; 2518 | } 2519 | declare module "core-js/library/fn/array/values" { 2520 | var values: typeof core.Array.values; 2521 | export = values; 2522 | } 2523 | declare module "core-js/library/fn/date" { 2524 | var Date: typeof core.Date; 2525 | export = Date; 2526 | } 2527 | declare module "core-js/library/fn/date/add-locale" { 2528 | var addLocale: typeof core.addLocale; 2529 | export = addLocale; 2530 | } 2531 | declare module "core-js/library/fn/date/format" { 2532 | var format: typeof core.Date.format; 2533 | export = format; 2534 | } 2535 | declare module "core-js/library/fn/date/formatUTC" { 2536 | var formatUTC: typeof core.Date.formatUTC; 2537 | export = formatUTC; 2538 | } 2539 | declare module "core-js/library/fn/function" { 2540 | var Function: typeof core.Function; 2541 | export = Function; 2542 | } 2543 | declare module "core-js/library/fn/function/has-instance" { 2544 | var hasInstance: (value: any) => boolean; 2545 | export = hasInstance; 2546 | } 2547 | declare module "core-js/library/fn/function/name" { 2548 | } 2549 | declare module "core-js/library/fn/function/part" { 2550 | var part: typeof core.Function.part; 2551 | export = part; 2552 | } 2553 | declare module "core-js/library/fn/math" { 2554 | var Math: typeof core.Math; 2555 | export = Math; 2556 | } 2557 | declare module "core-js/library/fn/math/acosh" { 2558 | var acosh: typeof core.Math.acosh; 2559 | export = acosh; 2560 | } 2561 | declare module "core-js/library/fn/math/asinh" { 2562 | var asinh: typeof core.Math.asinh; 2563 | export = asinh; 2564 | } 2565 | declare module "core-js/library/fn/math/atanh" { 2566 | var atanh: typeof core.Math.atanh; 2567 | export = atanh; 2568 | } 2569 | declare module "core-js/library/fn/math/cbrt" { 2570 | var cbrt: typeof core.Math.cbrt; 2571 | export = cbrt; 2572 | } 2573 | declare module "core-js/library/fn/math/clz32" { 2574 | var clz32: typeof core.Math.clz32; 2575 | export = clz32; 2576 | } 2577 | declare module "core-js/library/fn/math/cosh" { 2578 | var cosh: typeof core.Math.cosh; 2579 | export = cosh; 2580 | } 2581 | declare module "core-js/library/fn/math/expm1" { 2582 | var expm1: typeof core.Math.expm1; 2583 | export = expm1; 2584 | } 2585 | declare module "core-js/library/fn/math/fround" { 2586 | var fround: typeof core.Math.fround; 2587 | export = fround; 2588 | } 2589 | declare module "core-js/library/fn/math/hypot" { 2590 | var hypot: typeof core.Math.hypot; 2591 | export = hypot; 2592 | } 2593 | declare module "core-js/library/fn/math/imul" { 2594 | var imul: typeof core.Math.imul; 2595 | export = imul; 2596 | } 2597 | declare module "core-js/library/fn/math/log10" { 2598 | var log10: typeof core.Math.log10; 2599 | export = log10; 2600 | } 2601 | declare module "core-js/library/fn/math/log1p" { 2602 | var log1p: typeof core.Math.log1p; 2603 | export = log1p; 2604 | } 2605 | declare module "core-js/library/fn/math/log2" { 2606 | var log2: typeof core.Math.log2; 2607 | export = log2; 2608 | } 2609 | declare module "core-js/library/fn/math/sign" { 2610 | var sign: typeof core.Math.sign; 2611 | export = sign; 2612 | } 2613 | declare module "core-js/library/fn/math/sinh" { 2614 | var sinh: typeof core.Math.sinh; 2615 | export = sinh; 2616 | } 2617 | declare module "core-js/library/fn/math/tanh" { 2618 | var tanh: typeof core.Math.tanh; 2619 | export = tanh; 2620 | } 2621 | declare module "core-js/library/fn/math/trunc" { 2622 | var trunc: typeof core.Math.trunc; 2623 | export = trunc; 2624 | } 2625 | declare module "core-js/library/fn/number" { 2626 | var Number: typeof core.Number; 2627 | export = Number; 2628 | } 2629 | declare module "core-js/library/fn/number/epsilon" { 2630 | var EPSILON: typeof core.Number.EPSILON; 2631 | export = EPSILON; 2632 | } 2633 | declare module "core-js/library/fn/number/is-finite" { 2634 | var isFinite: typeof core.Number.isFinite; 2635 | export = isFinite; 2636 | } 2637 | declare module "core-js/library/fn/number/is-integer" { 2638 | var isInteger: typeof core.Number.isInteger; 2639 | export = isInteger; 2640 | } 2641 | declare module "core-js/library/fn/number/is-nan" { 2642 | var isNaN: typeof core.Number.isNaN; 2643 | export = isNaN; 2644 | } 2645 | declare module "core-js/library/fn/number/is-safe-integer" { 2646 | var isSafeInteger: typeof core.Number.isSafeInteger; 2647 | export = isSafeInteger; 2648 | } 2649 | declare module "core-js/library/fn/number/max-safe-integer" { 2650 | var MAX_SAFE_INTEGER: typeof core.Number.MAX_SAFE_INTEGER; 2651 | export = MAX_SAFE_INTEGER; 2652 | } 2653 | declare module "core-js/library/fn/number/min-safe-interger" { 2654 | var MIN_SAFE_INTEGER: typeof core.Number.MIN_SAFE_INTEGER; 2655 | export = MIN_SAFE_INTEGER; 2656 | } 2657 | declare module "core-js/library/fn/number/parse-float" { 2658 | var parseFloat: typeof core.Number.parseFloat; 2659 | export = parseFloat; 2660 | } 2661 | declare module "core-js/library/fn/number/parse-int" { 2662 | var parseInt: typeof core.Number.parseInt; 2663 | export = parseInt; 2664 | } 2665 | declare module "core-js/library/fn/number/random" { 2666 | var random: typeof core.Number.random; 2667 | export = random; 2668 | } 2669 | declare module "core-js/library/fn/object" { 2670 | var Object: typeof core.Object; 2671 | export = Object; 2672 | } 2673 | declare module "core-js/library/fn/object/assign" { 2674 | var assign: typeof core.Object.assign; 2675 | export = assign; 2676 | } 2677 | declare module "core-js/library/fn/object/classof" { 2678 | var classof: typeof core.Object.classof; 2679 | export = classof; 2680 | } 2681 | declare module "core-js/library/fn/object/create" { 2682 | var create: typeof core.Object.create; 2683 | export = create; 2684 | } 2685 | declare module "core-js/library/fn/object/define" { 2686 | var define: typeof core.Object.define; 2687 | export = define; 2688 | } 2689 | declare module "core-js/library/fn/object/define-properties" { 2690 | var defineProperties: typeof core.Object.defineProperties; 2691 | export = defineProperties; 2692 | } 2693 | declare module "core-js/library/fn/object/define-property" { 2694 | var defineProperty: typeof core.Object.defineProperty; 2695 | export = defineProperty; 2696 | } 2697 | declare module "core-js/library/fn/object/entries" { 2698 | var entries: typeof core.Object.entries; 2699 | export = entries; 2700 | } 2701 | declare module "core-js/library/fn/object/freeze" { 2702 | var freeze: typeof core.Object.freeze; 2703 | export = freeze; 2704 | } 2705 | declare module "core-js/library/fn/object/get-own-property-descriptor" { 2706 | var getOwnPropertyDescriptor: typeof core.Object.getOwnPropertyDescriptor; 2707 | export = getOwnPropertyDescriptor; 2708 | } 2709 | declare module "core-js/library/fn/object/get-own-property-descriptors" { 2710 | var getOwnPropertyDescriptors: typeof core.Object.getOwnPropertyDescriptors; 2711 | export = getOwnPropertyDescriptors; 2712 | } 2713 | declare module "core-js/library/fn/object/get-own-property-names" { 2714 | var getOwnPropertyNames: typeof core.Object.getOwnPropertyNames; 2715 | export = getOwnPropertyNames; 2716 | } 2717 | declare module "core-js/library/fn/object/get-own-property-symbols" { 2718 | var getOwnPropertySymbols: typeof core.Object.getOwnPropertySymbols; 2719 | export = getOwnPropertySymbols; 2720 | } 2721 | declare module "core-js/library/fn/object/get-prototype-of" { 2722 | var getPrototypeOf: typeof core.Object.getPrototypeOf; 2723 | export = getPrototypeOf; 2724 | } 2725 | declare module "core-js/library/fn/object/is" { 2726 | var is: typeof core.Object.is; 2727 | export = is; 2728 | } 2729 | declare module "core-js/library/fn/object/is-extensible" { 2730 | var isExtensible: typeof core.Object.isExtensible; 2731 | export = isExtensible; 2732 | } 2733 | declare module "core-js/library/fn/object/is-frozen" { 2734 | var isFrozen: typeof core.Object.isFrozen; 2735 | export = isFrozen; 2736 | } 2737 | declare module "core-js/library/fn/object/is-object" { 2738 | var isObject: typeof core.Object.isObject; 2739 | export = isObject; 2740 | } 2741 | declare module "core-js/library/fn/object/is-sealed" { 2742 | var isSealed: typeof core.Object.isSealed; 2743 | export = isSealed; 2744 | } 2745 | declare module "core-js/library/fn/object/keys" { 2746 | var keys: typeof core.Object.keys; 2747 | export = keys; 2748 | } 2749 | declare module "core-js/library/fn/object/make" { 2750 | var make: typeof core.Object.make; 2751 | export = make; 2752 | } 2753 | declare module "core-js/library/fn/object/prevent-extensions" { 2754 | var preventExtensions: typeof core.Object.preventExtensions; 2755 | export = preventExtensions; 2756 | } 2757 | declare module "core-js/library/fn/object/seal" { 2758 | var seal: typeof core.Object.seal; 2759 | export = seal; 2760 | } 2761 | declare module "core-js/library/fn/object/set-prototype-of" { 2762 | var setPrototypeOf: typeof core.Object.setPrototypeOf; 2763 | export = setPrototypeOf; 2764 | } 2765 | declare module "core-js/library/fn/object/values" { 2766 | var values: typeof core.Object.values; 2767 | export = values; 2768 | } 2769 | declare module "core-js/library/fn/reflect" { 2770 | var Reflect: typeof core.Reflect; 2771 | export = Reflect; 2772 | } 2773 | declare module "core-js/library/fn/reflect/apply" { 2774 | var apply: typeof core.Reflect.apply; 2775 | export = apply; 2776 | } 2777 | declare module "core-js/library/fn/reflect/construct" { 2778 | var construct: typeof core.Reflect.construct; 2779 | export = construct; 2780 | } 2781 | declare module "core-js/library/fn/reflect/define-property" { 2782 | var defineProperty: typeof core.Reflect.defineProperty; 2783 | export = defineProperty; 2784 | } 2785 | declare module "core-js/library/fn/reflect/delete-property" { 2786 | var deleteProperty: typeof core.Reflect.deleteProperty; 2787 | export = deleteProperty; 2788 | } 2789 | declare module "core-js/library/fn/reflect/enumerate" { 2790 | var enumerate: typeof core.Reflect.enumerate; 2791 | export = enumerate; 2792 | } 2793 | declare module "core-js/library/fn/reflect/get" { 2794 | var get: typeof core.Reflect.get; 2795 | export = get; 2796 | } 2797 | declare module "core-js/library/fn/reflect/get-own-property-descriptor" { 2798 | var getOwnPropertyDescriptor: typeof core.Reflect.getOwnPropertyDescriptor; 2799 | export = getOwnPropertyDescriptor; 2800 | } 2801 | declare module "core-js/library/fn/reflect/get-prototype-of" { 2802 | var getPrototypeOf: typeof core.Reflect.getPrototypeOf; 2803 | export = getPrototypeOf; 2804 | } 2805 | declare module "core-js/library/fn/reflect/has" { 2806 | var has: typeof core.Reflect.has; 2807 | export = has; 2808 | } 2809 | declare module "core-js/library/fn/reflect/is-extensible" { 2810 | var isExtensible: typeof core.Reflect.isExtensible; 2811 | export = isExtensible; 2812 | } 2813 | declare module "core-js/library/fn/reflect/own-keys" { 2814 | var ownKeys: typeof core.Reflect.ownKeys; 2815 | export = ownKeys; 2816 | } 2817 | declare module "core-js/library/fn/reflect/prevent-extensions" { 2818 | var preventExtensions: typeof core.Reflect.preventExtensions; 2819 | export = preventExtensions; 2820 | } 2821 | declare module "core-js/library/fn/reflect/set" { 2822 | var set: typeof core.Reflect.set; 2823 | export = set; 2824 | } 2825 | declare module "core-js/library/fn/reflect/set-prototype-of" { 2826 | var setPrototypeOf: typeof core.Reflect.setPrototypeOf; 2827 | export = setPrototypeOf; 2828 | } 2829 | declare module "core-js/library/fn/regexp" { 2830 | var RegExp: typeof core.RegExp; 2831 | export = RegExp; 2832 | } 2833 | declare module "core-js/library/fn/regexp/escape" { 2834 | var escape: typeof core.RegExp.escape; 2835 | export = escape; 2836 | } 2837 | declare module "core-js/library/fn/string" { 2838 | var String: typeof core.String; 2839 | export = String; 2840 | } 2841 | declare module "core-js/library/fn/string/at" { 2842 | var at: typeof core.String.at; 2843 | export = at; 2844 | } 2845 | declare module "core-js/library/fn/string/code-point-at" { 2846 | var codePointAt: typeof core.String.codePointAt; 2847 | export = codePointAt; 2848 | } 2849 | declare module "core-js/library/fn/string/ends-with" { 2850 | var endsWith: typeof core.String.endsWith; 2851 | export = endsWith; 2852 | } 2853 | declare module "core-js/library/fn/string/escape-html" { 2854 | var escapeHTML: typeof core.String.escapeHTML; 2855 | export = escapeHTML; 2856 | } 2857 | declare module "core-js/library/fn/string/from-code-point" { 2858 | var fromCodePoint: typeof core.String.fromCodePoint; 2859 | export = fromCodePoint; 2860 | } 2861 | declare module "core-js/library/fn/string/includes" { 2862 | var includes: typeof core.String.includes; 2863 | export = includes; 2864 | } 2865 | declare module "core-js/library/fn/string/lpad" { 2866 | var lpad: typeof core.String.lpad; 2867 | export = lpad; 2868 | } 2869 | declare module "core-js/library/fn/string/raw" { 2870 | var raw: typeof core.String.raw; 2871 | export = raw; 2872 | } 2873 | declare module "core-js/library/fn/string/repeat" { 2874 | var repeat: typeof core.String.repeat; 2875 | export = repeat; 2876 | } 2877 | declare module "core-js/library/fn/string/rpad" { 2878 | var rpad: typeof core.String.rpad; 2879 | export = rpad; 2880 | } 2881 | declare module "core-js/library/fn/string/starts-with" { 2882 | var startsWith: typeof core.String.startsWith; 2883 | export = startsWith; 2884 | } 2885 | declare module "core-js/library/fn/string/unescape-html" { 2886 | var unescapeHTML: typeof core.String.unescapeHTML; 2887 | export = unescapeHTML; 2888 | } 2889 | declare module "core-js/library/fn/symbol" { 2890 | var Symbol: typeof core.Symbol; 2891 | export = Symbol; 2892 | } 2893 | declare module "core-js/library/fn/symbol/for" { 2894 | var _for: typeof core.Symbol.for; 2895 | export = _for; 2896 | } 2897 | declare module "core-js/library/fn/symbol/has-instance" { 2898 | var hasInstance: typeof core.Symbol.hasInstance; 2899 | export = hasInstance; 2900 | } 2901 | declare module "core-js/library/fn/symbol/is-concat-spreadable" { 2902 | var isConcatSpreadable: typeof core.Symbol.isConcatSpreadable; 2903 | export = isConcatSpreadable; 2904 | } 2905 | declare module "core-js/library/fn/symbol/iterator" { 2906 | var iterator: typeof core.Symbol.iterator; 2907 | export = iterator; 2908 | } 2909 | declare module "core-js/library/fn/symbol/key-for" { 2910 | var keyFor: typeof core.Symbol.keyFor; 2911 | export = keyFor; 2912 | } 2913 | declare module "core-js/library/fn/symbol/match" { 2914 | var match: typeof core.Symbol.match; 2915 | export = match; 2916 | } 2917 | declare module "core-js/library/fn/symbol/replace" { 2918 | var replace: typeof core.Symbol.replace; 2919 | export = replace; 2920 | } 2921 | declare module "core-js/library/fn/symbol/search" { 2922 | var search: typeof core.Symbol.search; 2923 | export = search; 2924 | } 2925 | declare module "core-js/library/fn/symbol/species" { 2926 | var species: typeof core.Symbol.species; 2927 | export = species; 2928 | } 2929 | declare module "core-js/library/fn/symbol/split" { 2930 | var split: typeof core.Symbol.split; 2931 | export = split; 2932 | } 2933 | declare module "core-js/library/fn/symbol/to-primitive" { 2934 | var toPrimitive: typeof core.Symbol.toPrimitive; 2935 | export = toPrimitive; 2936 | } 2937 | declare module "core-js/library/fn/symbol/to-string-tag" { 2938 | var toStringTag: typeof core.Symbol.toStringTag; 2939 | export = toStringTag; 2940 | } 2941 | declare module "core-js/library/fn/symbol/unscopables" { 2942 | var unscopables: typeof core.Symbol.unscopables; 2943 | export = unscopables; 2944 | } 2945 | declare module "core-js/library/es5" { 2946 | export = core; 2947 | } 2948 | declare module "core-js/library/es6" { 2949 | export = core; 2950 | } 2951 | declare module "core-js/library/es6/array" { 2952 | var Array: typeof core.Array; 2953 | export = Array; 2954 | } 2955 | declare module "core-js/library/es6/function" { 2956 | var Function: typeof core.Function; 2957 | export = Function; 2958 | } 2959 | declare module "core-js/library/es6/map" { 2960 | var Map: typeof core.Map; 2961 | export = Map; 2962 | } 2963 | declare module "core-js/library/es6/math" { 2964 | var Math: typeof core.Math; 2965 | export = Math; 2966 | } 2967 | declare module "core-js/library/es6/number" { 2968 | var Number: typeof core.Number; 2969 | export = Number; 2970 | } 2971 | declare module "core-js/library/es6/object" { 2972 | var Object: typeof core.Object; 2973 | export = Object; 2974 | } 2975 | declare module "core-js/library/es6/promise" { 2976 | var Promise: typeof core.Promise; 2977 | export = Promise; 2978 | } 2979 | declare module "core-js/library/es6/reflect" { 2980 | var Reflect: typeof core.Reflect; 2981 | export = Reflect; 2982 | } 2983 | declare module "core-js/library/es6/regexp" { 2984 | var RegExp: typeof core.RegExp; 2985 | export = RegExp; 2986 | } 2987 | declare module "core-js/library/es6/set" { 2988 | var Set: typeof core.Set; 2989 | export = Set; 2990 | } 2991 | declare module "core-js/library/es6/string" { 2992 | var String: typeof core.String; 2993 | export = String; 2994 | } 2995 | declare module "core-js/library/es6/symbol" { 2996 | var Symbol: typeof core.Symbol; 2997 | export = Symbol; 2998 | } 2999 | declare module "core-js/library/es6/weak-map" { 3000 | var WeakMap: typeof core.WeakMap; 3001 | export = WeakMap; 3002 | } 3003 | declare module "core-js/library/es6/weak-set" { 3004 | var WeakSet: typeof core.WeakSet; 3005 | export = WeakSet; 3006 | } 3007 | declare module "core-js/library/es7" { 3008 | export = core; 3009 | } 3010 | declare module "core-js/library/es7/array" { 3011 | var Array: typeof core.Array; 3012 | export = Array; 3013 | } 3014 | declare module "core-js/library/es7/map" { 3015 | var Map: typeof core.Map; 3016 | export = Map; 3017 | } 3018 | declare module "core-js/library/es7/object" { 3019 | var Object: typeof core.Object; 3020 | export = Object; 3021 | } 3022 | declare module "core-js/library/es7/regexp" { 3023 | var RegExp: typeof core.RegExp; 3024 | export = RegExp; 3025 | } 3026 | declare module "core-js/library/es7/set" { 3027 | var Set: typeof core.Set; 3028 | export = Set; 3029 | } 3030 | declare module "core-js/library/es7/string" { 3031 | var String: typeof core.String; 3032 | export = String; 3033 | } 3034 | declare module "core-js/library/js" { 3035 | export = core; 3036 | } 3037 | declare module "core-js/library/js/array" { 3038 | var Array: typeof core.Array; 3039 | export = Array; 3040 | } 3041 | declare module "core-js/library/web" { 3042 | export = core; 3043 | } 3044 | declare module "core-js/library/web/dom" { 3045 | export = core; 3046 | } 3047 | declare module "core-js/library/web/immediate" { 3048 | export = core; 3049 | } 3050 | declare module "core-js/library/web/timers" { 3051 | export = core; 3052 | } 3053 | -------------------------------------------------------------------------------- /angular2-app/typings/globals/core-js/typings.json: -------------------------------------------------------------------------------- 1 | { 2 | "resolution": "main", 3 | "tree": { 4 | "src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/25e18b592470e3dddccc826fde2bb8e7610ef863/core-js/core-js.d.ts", 5 | "raw": "registry:dt/core-js#0.0.0+20160725163759", 6 | "typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/25e18b592470e3dddccc826fde2bb8e7610ef863/core-js/core-js.d.ts" 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /angular2-app/typings/globals/jasmine/index.d.ts: -------------------------------------------------------------------------------- 1 | // Generated by typings 2 | // Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/c49913aa9ea419ea46c1c684e488cf2a10303b1a/jasmine/jasmine.d.ts 3 | declare function describe(description: string, specDefinitions: () => void): void; 4 | declare function fdescribe(description: string, specDefinitions: () => void): void; 5 | declare function xdescribe(description: string, specDefinitions: () => void): void; 6 | 7 | declare function it(expectation: string, assertion?: () => void, timeout?: number): void; 8 | declare function it(expectation: string, assertion?: (done: DoneFn) => void, timeout?: number): void; 9 | declare function fit(expectation: string, assertion?: () => void, timeout?: number): void; 10 | declare function fit(expectation: string, assertion?: (done: DoneFn) => void, timeout?: number): void; 11 | declare function xit(expectation: string, assertion?: () => void, timeout?: number): void; 12 | declare function xit(expectation: string, assertion?: (done: DoneFn) => void, timeout?: number): void; 13 | 14 | /** If you call the function pending anywhere in the spec body, no matter the expectations, the spec will be marked pending. */ 15 | declare function pending(reason?: string): void; 16 | 17 | declare function beforeEach(action: () => void, timeout?: number): void; 18 | declare function beforeEach(action: (done: DoneFn) => void, timeout?: number): void; 19 | declare function afterEach(action: () => void, timeout?: number): void; 20 | declare function afterEach(action: (done: DoneFn) => void, timeout?: number): void; 21 | 22 | declare function beforeAll(action: () => void, timeout?: number): void; 23 | declare function beforeAll(action: (done: DoneFn) => void, timeout?: number): void; 24 | declare function afterAll(action: () => void, timeout?: number): void; 25 | declare function afterAll(action: (done: DoneFn) => void, timeout?: number): void; 26 | 27 | declare function expect(spy: Function): jasmine.Matchers; 28 | declare function expect(actual: any): jasmine.Matchers; 29 | 30 | declare function fail(e?: any): void; 31 | /** Action method that should be called when the async work is complete */ 32 | interface DoneFn extends Function { 33 | (): void; 34 | 35 | /** fails the spec and indicates that it has completed. If the message is an Error, Error.message is used */ 36 | fail: (message?: Error|string) => void; 37 | } 38 | 39 | declare function spyOn(object: any, method: string): jasmine.Spy; 40 | 41 | declare function runs(asyncMethod: Function): void; 42 | declare function waitsFor(latchMethod: () => boolean, failureMessage?: string, timeout?: number): void; 43 | declare function waits(timeout?: number): void; 44 | 45 | declare namespace jasmine { 46 | 47 | var clock: () => Clock; 48 | 49 | function any(aclass: any): Any; 50 | function anything(): Any; 51 | function arrayContaining(sample: any[]): ArrayContaining; 52 | function objectContaining(sample: any): ObjectContaining; 53 | function createSpy(name: string, originalFn?: Function): Spy; 54 | function createSpyObj(baseName: string, methodNames: any[]): any; 55 | function createSpyObj(baseName: string, methodNames: any[]): T; 56 | function pp(value: any): string; 57 | function getEnv(): Env; 58 | function addCustomEqualityTester(equalityTester: CustomEqualityTester): void; 59 | function addMatchers(matchers: CustomMatcherFactories): void; 60 | function stringMatching(str: string): Any; 61 | function stringMatching(str: RegExp): Any; 62 | 63 | interface Any { 64 | 65 | new (expectedClass: any): any; 66 | 67 | jasmineMatches(other: any): boolean; 68 | jasmineToString(): string; 69 | } 70 | 71 | // taken from TypeScript lib.core.es6.d.ts, applicable to CustomMatchers.contains() 72 | interface ArrayLike { 73 | length: number; 74 | [n: number]: T; 75 | } 76 | 77 | interface ArrayContaining { 78 | new (sample: any[]): any; 79 | 80 | asymmetricMatch(other: any): boolean; 81 | jasmineToString(): string; 82 | } 83 | 84 | interface ObjectContaining { 85 | new (sample: any): any; 86 | 87 | jasmineMatches(other: any, mismatchKeys: any[], mismatchValues: any[]): boolean; 88 | jasmineToString(): string; 89 | } 90 | 91 | interface Block { 92 | 93 | new (env: Env, func: SpecFunction, spec: Spec): any; 94 | 95 | execute(onComplete: () => void): void; 96 | } 97 | 98 | interface WaitsBlock extends Block { 99 | new (env: Env, timeout: number, spec: Spec): any; 100 | } 101 | 102 | interface WaitsForBlock extends Block { 103 | new (env: Env, timeout: number, latchFunction: SpecFunction, message: string, spec: Spec): any; 104 | } 105 | 106 | interface Clock { 107 | install(): void; 108 | uninstall(): void; 109 | /** Calls to any registered callback are triggered when the clock is ticked forward via the jasmine.clock().tick function, which takes a number of milliseconds. */ 110 | tick(ms: number): void; 111 | mockDate(date?: Date): void; 112 | } 113 | 114 | interface CustomEqualityTester { 115 | (first: any, second: any): boolean; 116 | } 117 | 118 | interface CustomMatcher { 119 | compare(actual: T, expected: T): CustomMatcherResult; 120 | compare(actual: any, expected: any): CustomMatcherResult; 121 | } 122 | 123 | interface CustomMatcherFactory { 124 | (util: MatchersUtil, customEqualityTesters: Array): CustomMatcher; 125 | } 126 | 127 | interface CustomMatcherFactories { 128 | [index: string]: CustomMatcherFactory; 129 | } 130 | 131 | interface CustomMatcherResult { 132 | pass: boolean; 133 | message?: string; 134 | } 135 | 136 | interface MatchersUtil { 137 | equals(a: any, b: any, customTesters?: Array): boolean; 138 | contains(haystack: ArrayLike | string, needle: any, customTesters?: Array): boolean; 139 | buildFailureMessage(matcherName: string, isNot: boolean, actual: any, ...expected: Array): string; 140 | } 141 | 142 | interface Env { 143 | setTimeout: any; 144 | clearTimeout: void; 145 | setInterval: any; 146 | clearInterval: void; 147 | updateInterval: number; 148 | 149 | currentSpec: Spec; 150 | 151 | matchersClass: Matchers; 152 | 153 | version(): any; 154 | versionString(): string; 155 | nextSpecId(): number; 156 | addReporter(reporter: Reporter): void; 157 | execute(): void; 158 | describe(description: string, specDefinitions: () => void): Suite; 159 | // ddescribe(description: string, specDefinitions: () => void): Suite; Not a part of jasmine. Angular team adds these 160 | beforeEach(beforeEachFunction: () => void): void; 161 | beforeAll(beforeAllFunction: () => void): void; 162 | currentRunner(): Runner; 163 | afterEach(afterEachFunction: () => void): void; 164 | afterAll(afterAllFunction: () => void): void; 165 | xdescribe(desc: string, specDefinitions: () => void): XSuite; 166 | it(description: string, func: () => void): Spec; 167 | // iit(description: string, func: () => void): Spec; Not a part of jasmine. Angular team adds these 168 | xit(desc: string, func: () => void): XSpec; 169 | compareRegExps_(a: RegExp, b: RegExp, mismatchKeys: string[], mismatchValues: string[]): boolean; 170 | compareObjects_(a: any, b: any, mismatchKeys: string[], mismatchValues: string[]): boolean; 171 | equals_(a: any, b: any, mismatchKeys: string[], mismatchValues: string[]): boolean; 172 | contains_(haystack: any, needle: any): boolean; 173 | addCustomEqualityTester(equalityTester: CustomEqualityTester): void; 174 | addMatchers(matchers: CustomMatcherFactories): void; 175 | specFilter(spec: Spec): boolean; 176 | throwOnExpectationFailure(value: boolean): void; 177 | } 178 | 179 | interface FakeTimer { 180 | 181 | new (): any; 182 | 183 | reset(): void; 184 | tick(millis: number): void; 185 | runFunctionsWithinRange(oldMillis: number, nowMillis: number): void; 186 | scheduleFunction(timeoutKey: any, funcToCall: () => void, millis: number, recurring: boolean): void; 187 | } 188 | 189 | interface HtmlReporter { 190 | new (): any; 191 | } 192 | 193 | interface HtmlSpecFilter { 194 | new (): any; 195 | } 196 | 197 | interface Result { 198 | type: string; 199 | } 200 | 201 | interface NestedResults extends Result { 202 | description: string; 203 | 204 | totalCount: number; 205 | passedCount: number; 206 | failedCount: number; 207 | 208 | skipped: boolean; 209 | 210 | rollupCounts(result: NestedResults): void; 211 | log(values: any): void; 212 | getItems(): Result[]; 213 | addResult(result: Result): void; 214 | passed(): boolean; 215 | } 216 | 217 | interface MessageResult extends Result { 218 | values: any; 219 | trace: Trace; 220 | } 221 | 222 | interface ExpectationResult extends Result { 223 | matcherName: string; 224 | passed(): boolean; 225 | expected: any; 226 | actual: any; 227 | message: string; 228 | trace: Trace; 229 | } 230 | 231 | interface Trace { 232 | name: string; 233 | message: string; 234 | stack: any; 235 | } 236 | 237 | interface PrettyPrinter { 238 | 239 | new (): any; 240 | 241 | format(value: any): void; 242 | iterateObject(obj: any, fn: (property: string, isGetter: boolean) => void): void; 243 | emitScalar(value: any): void; 244 | emitString(value: string): void; 245 | emitArray(array: any[]): void; 246 | emitObject(obj: any): void; 247 | append(value: any): void; 248 | } 249 | 250 | interface StringPrettyPrinter extends PrettyPrinter { 251 | } 252 | 253 | interface Queue { 254 | 255 | new (env: any): any; 256 | 257 | env: Env; 258 | ensured: boolean[]; 259 | blocks: Block[]; 260 | running: boolean; 261 | index: number; 262 | offset: number; 263 | abort: boolean; 264 | 265 | addBefore(block: Block, ensure?: boolean): void; 266 | add(block: any, ensure?: boolean): void; 267 | insertNext(block: any, ensure?: boolean): void; 268 | start(onComplete?: () => void): void; 269 | isRunning(): boolean; 270 | next_(): void; 271 | results(): NestedResults; 272 | } 273 | 274 | interface Matchers { 275 | 276 | new (env: Env, actual: any, spec: Env, isNot?: boolean): any; 277 | 278 | env: Env; 279 | actual: any; 280 | spec: Env; 281 | isNot?: boolean; 282 | message(): any; 283 | 284 | toBe(expected: any, expectationFailOutput?: any): boolean; 285 | toEqual(expected: any, expectationFailOutput?: any): boolean; 286 | toMatch(expected: string | RegExp, expectationFailOutput?: any): boolean; 287 | toBeDefined(expectationFailOutput?: any): boolean; 288 | toBeUndefined(expectationFailOutput?: any): boolean; 289 | toBeNull(expectationFailOutput?: any): boolean; 290 | toBeNaN(): boolean; 291 | toBeTruthy(expectationFailOutput?: any): boolean; 292 | toBeFalsy(expectationFailOutput?: any): boolean; 293 | toHaveBeenCalled(): boolean; 294 | toHaveBeenCalledWith(...params: any[]): boolean; 295 | toHaveBeenCalledTimes(expected: number): boolean; 296 | toContain(expected: any, expectationFailOutput?: any): boolean; 297 | toBeLessThan(expected: number, expectationFailOutput?: any): boolean; 298 | toBeGreaterThan(expected: number, expectationFailOutput?: any): boolean; 299 | toBeCloseTo(expected: number, precision?: any, expectationFailOutput?: any): boolean; 300 | toThrow(expected?: any): boolean; 301 | toThrowError(message?: string | RegExp): boolean; 302 | toThrowError(expected?: new (...args: any[]) => Error, message?: string | RegExp): boolean; 303 | not: Matchers; 304 | 305 | Any: Any; 306 | } 307 | 308 | interface Reporter { 309 | reportRunnerStarting(runner: Runner): void; 310 | reportRunnerResults(runner: Runner): void; 311 | reportSuiteResults(suite: Suite): void; 312 | reportSpecStarting(spec: Spec): void; 313 | reportSpecResults(spec: Spec): void; 314 | log(str: string): void; 315 | } 316 | 317 | interface MultiReporter extends Reporter { 318 | addReporter(reporter: Reporter): void; 319 | } 320 | 321 | interface Runner { 322 | 323 | new (env: Env): any; 324 | 325 | execute(): void; 326 | beforeEach(beforeEachFunction: SpecFunction): void; 327 | afterEach(afterEachFunction: SpecFunction): void; 328 | beforeAll(beforeAllFunction: SpecFunction): void; 329 | afterAll(afterAllFunction: SpecFunction): void; 330 | finishCallback(): void; 331 | addSuite(suite: Suite): void; 332 | add(block: Block): void; 333 | specs(): Spec[]; 334 | suites(): Suite[]; 335 | topLevelSuites(): Suite[]; 336 | results(): NestedResults; 337 | } 338 | 339 | interface SpecFunction { 340 | (spec?: Spec): void; 341 | } 342 | 343 | interface SuiteOrSpec { 344 | id: number; 345 | env: Env; 346 | description: string; 347 | queue: Queue; 348 | } 349 | 350 | interface Spec extends SuiteOrSpec { 351 | 352 | new (env: Env, suite: Suite, description: string): any; 353 | 354 | suite: Suite; 355 | 356 | afterCallbacks: SpecFunction[]; 357 | spies_: Spy[]; 358 | 359 | results_: NestedResults; 360 | matchersClass: Matchers; 361 | 362 | getFullName(): string; 363 | results(): NestedResults; 364 | log(arguments: any): any; 365 | runs(func: SpecFunction): Spec; 366 | addToQueue(block: Block): void; 367 | addMatcherResult(result: Result): void; 368 | expect(actual: any): any; 369 | waits(timeout: number): Spec; 370 | waitsFor(latchFunction: SpecFunction, timeoutMessage?: string, timeout?: number): Spec; 371 | fail(e?: any): void; 372 | getMatchersClass_(): Matchers; 373 | addMatchers(matchersPrototype: CustomMatcherFactories): void; 374 | finishCallback(): void; 375 | finish(onComplete?: () => void): void; 376 | after(doAfter: SpecFunction): void; 377 | execute(onComplete?: () => void): any; 378 | addBeforesAndAftersToQueue(): void; 379 | explodes(): void; 380 | spyOn(obj: any, methodName: string, ignoreMethodDoesntExist: boolean): Spy; 381 | removeAllSpies(): void; 382 | } 383 | 384 | interface XSpec { 385 | id: number; 386 | runs(): void; 387 | } 388 | 389 | interface Suite extends SuiteOrSpec { 390 | 391 | new (env: Env, description: string, specDefinitions: () => void, parentSuite: Suite): any; 392 | 393 | parentSuite: Suite; 394 | 395 | getFullName(): string; 396 | finish(onComplete?: () => void): void; 397 | beforeEach(beforeEachFunction: SpecFunction): void; 398 | afterEach(afterEachFunction: SpecFunction): void; 399 | beforeAll(beforeAllFunction: SpecFunction): void; 400 | afterAll(afterAllFunction: SpecFunction): void; 401 | results(): NestedResults; 402 | add(suiteOrSpec: SuiteOrSpec): void; 403 | specs(): Spec[]; 404 | suites(): Suite[]; 405 | children(): any[]; 406 | execute(onComplete?: () => void): void; 407 | } 408 | 409 | interface XSuite { 410 | execute(): void; 411 | } 412 | 413 | interface Spy { 414 | (...params: any[]): any; 415 | 416 | identity: string; 417 | and: SpyAnd; 418 | calls: Calls; 419 | mostRecentCall: { args: any[]; }; 420 | argsForCall: any[]; 421 | wasCalled: boolean; 422 | } 423 | 424 | interface SpyAnd { 425 | /** By chaining the spy with and.callThrough, the spy will still track all calls to it but in addition it will delegate to the actual implementation. */ 426 | callThrough(): Spy; 427 | /** By chaining the spy with and.returnValue, all calls to the function will return a specific value. */ 428 | returnValue(val: any): Spy; 429 | /** By chaining the spy with and.returnValues, all calls to the function will return specific values in order until it reaches the end of the return values list. */ 430 | returnValues(...values: any[]): Spy; 431 | /** By chaining the spy with and.callFake, all calls to the spy will delegate to the supplied function. */ 432 | callFake(fn: Function): Spy; 433 | /** By chaining the spy with and.throwError, all calls to the spy will throw the specified value. */ 434 | throwError(msg: string): Spy; 435 | /** When a calling strategy is used for a spy, the original stubbing behavior can be returned at any time with and.stub. */ 436 | stub(): Spy; 437 | } 438 | 439 | interface Calls { 440 | /** By chaining the spy with calls.any(), will return false if the spy has not been called at all, and then true once at least one call happens. **/ 441 | any(): boolean; 442 | /** By chaining the spy with calls.count(), will return the number of times the spy was called **/ 443 | count(): number; 444 | /** By chaining the spy with calls.argsFor(), will return the arguments passed to call number index **/ 445 | argsFor(index: number): any[]; 446 | /** By chaining the spy with calls.allArgs(), will return the arguments to all calls **/ 447 | allArgs(): any[]; 448 | /** By chaining the spy with calls.all(), will return the context (the this) and arguments passed all calls **/ 449 | all(): CallInfo[]; 450 | /** By chaining the spy with calls.mostRecent(), will return the context (the this) and arguments for the most recent call **/ 451 | mostRecent(): CallInfo; 452 | /** By chaining the spy with calls.first(), will return the context (the this) and arguments for the first call **/ 453 | first(): CallInfo; 454 | /** By chaining the spy with calls.reset(), will clears all tracking for a spy **/ 455 | reset(): void; 456 | } 457 | 458 | interface CallInfo { 459 | /** The context (the this) for the call */ 460 | object: any; 461 | /** All arguments passed to the call */ 462 | args: any[]; 463 | /** The return value of the call */ 464 | returnValue: any; 465 | } 466 | 467 | interface Util { 468 | inherit(childClass: Function, parentClass: Function): any; 469 | formatException(e: any): any; 470 | htmlEscape(str: string): string; 471 | argsToArray(args: any): any; 472 | extend(destination: any, source: any): any; 473 | } 474 | 475 | interface JsApiReporter extends Reporter { 476 | 477 | started: boolean; 478 | finished: boolean; 479 | result: any; 480 | messages: any; 481 | 482 | new (): any; 483 | 484 | suites(): Suite[]; 485 | summarize_(suiteOrSpec: SuiteOrSpec): any; 486 | results(): any; 487 | resultsForSpec(specId: any): any; 488 | log(str: any): any; 489 | resultsForSpecs(specIds: any): any; 490 | summarizeResult_(result: any): any; 491 | } 492 | 493 | interface Jasmine { 494 | Spec: Spec; 495 | clock: Clock; 496 | util: Util; 497 | } 498 | 499 | export var HtmlReporter: HtmlReporter; 500 | export var HtmlSpecFilter: HtmlSpecFilter; 501 | export var DEFAULT_TIMEOUT_INTERVAL: number; 502 | } 503 | -------------------------------------------------------------------------------- /angular2-app/typings/globals/jasmine/typings.json: -------------------------------------------------------------------------------- 1 | { 2 | "resolution": "main", 3 | "tree": { 4 | "src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/c49913aa9ea419ea46c1c684e488cf2a10303b1a/jasmine/jasmine.d.ts", 5 | "raw": "registry:dt/jasmine#2.2.0+20160621224255", 6 | "typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/c49913aa9ea419ea46c1c684e488cf2a10303b1a/jasmine/jasmine.d.ts" 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /angular2-app/typings/globals/node/typings.json: -------------------------------------------------------------------------------- 1 | { 2 | "resolution": "main", 3 | "tree": { 4 | "src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/4008a51db44dabcdc368097a39a01ab7a5f9587f/node/node.d.ts", 5 | "raw": "registry:dt/node#6.0.0+20160909174046", 6 | "typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/4008a51db44dabcdc368097a39a01ab7a5f9587f/node/node.d.ts" 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /angular2-app/typings/index.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | /// 3 | /// 4 | -------------------------------------------------------------------------------- /app.js: -------------------------------------------------------------------------------- 1 | var express = require('express'); 2 | var app = express(); 3 | var bodyParser = require('body-parser'); 4 | var mongoose = require('mongoose'); 5 | mongoose.connect('mongodb://127.0.0.1/gridfstest'); 6 | var conn = mongoose.connection; 7 | var multer = require('multer'); 8 | var GridFsStorage = require('multer-gridfs-storage'); 9 | var Grid = require('gridfs-stream'); 10 | Grid.mongo = mongoose.mongo; 11 | var gfs = Grid(conn.db); 12 | 13 | /** Seting up server to accept cross-origin browser requests */ 14 | app.use(function(req, res, next) { //allow cross origin requests 15 | res.setHeader("Access-Control-Allow-Methods", "POST, PUT, OPTIONS, DELETE, GET"); 16 | res.header("Access-Control-Allow-Origin", "http://localhost:3000"); 17 | res.header("Access-Control-Allow-Headers", "Origin, X-Requested-With, Content-Type, Accept"); 18 | res.header("Access-Control-Allow-Credentials", true); 19 | next(); 20 | }); 21 | 22 | app.use(bodyParser.json()); 23 | 24 | /** Setting up storage using multer-gridfs-storage */ 25 | var storage = GridFsStorage({ 26 | gfs : gfs, 27 | filename: function (req, file, cb) { 28 | var datetimestamp = Date.now(); 29 | cb(null, file.fieldname + '-' + datetimestamp + '.' + file.originalname.split('.')[file.originalname.split('.').length -1]); 30 | }, 31 | /** With gridfs we can store aditional meta-data along with the file */ 32 | metadata: function(req, file, cb) { 33 | cb(null, { originalname: file.originalname }); 34 | }, 35 | root: 'ctFiles' //root name for collection to store files into 36 | }); 37 | 38 | var upload = multer({ //multer settings for single upload 39 | storage: storage 40 | }).single('file'); 41 | 42 | /** API path that will upload the files */ 43 | app.post('/upload', function(req, res) { 44 | upload(req,res,function(err){ 45 | if(err){ 46 | res.json({error_code:1,err_desc:err}); 47 | return; 48 | } 49 | res.json({error_code:0,err_desc:null}); 50 | }); 51 | }); 52 | 53 | app.get('/file/:filename', function(req, res){ 54 | gfs.collection('ctFiles'); //set collection name to lookup into 55 | 56 | /** First check if file exists */ 57 | gfs.files.find({filename: req.params.filename}).toArray(function(err, files){ 58 | if(!files || files.length === 0){ 59 | return res.status(404).json({ 60 | responseCode: 1, 61 | responseMessage: "error" 62 | }); 63 | } 64 | /** create read stream */ 65 | var readstream = gfs.createReadStream({ 66 | filename: files[0].filename, 67 | root: "ctFiles" 68 | }); 69 | /** set the proper content type */ 70 | res.set('Content-Type', files[0].contentType) 71 | /** return response */ 72 | return readstream.pipe(res); 73 | }); 74 | }); 75 | 76 | app.listen('3002', function(){ 77 | console.log('running on 3002...'); 78 | }); -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "file-upload-gridfs", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "keywords": [], 10 | "author": "", 11 | "license": "ISC", 12 | "dependencies": { 13 | "body-parser": "1.16.1", 14 | "express": "4.14.1", 15 | "gridfs-stream": "1.1.1", 16 | "mongoose": "4.8.4", 17 | "multer": "1.3.0", 18 | "multer-gridfs-storage": "1.0.0" 19 | } 20 | } 21 | --------------------------------------------------------------------------------