diff --git a/DataStream.js/tsconfig.json b/DataStream.js/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/DataStream.js/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/FileSaver/tsconfig.json b/FileSaver/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/FileSaver/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/Finch/tsconfig.json b/Finch/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/Finch/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/Headroom/tsconfig.json b/Headroom/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/Headroom/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/HubSpot-pace/tsconfig.json b/HubSpot-pace/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/HubSpot-pace/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/JSONStream/tsconfig.json b/JSONStream/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/JSONStream/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/OpenJsCad/tsconfig.json b/OpenJsCad/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/OpenJsCad/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/PayPal-Cordova-Plugin/tsconfig.json b/PayPal-Cordova-Plugin/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/PayPal-Cordova-Plugin/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/_debugger/tsconfig.json b/_debugger/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/_debugger/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/abs/tsconfig.json b/abs/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/abs/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/absolute/tsconfig.json b/absolute/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/absolute/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/acc-wizard/tsconfig.json b/acc-wizard/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/acc-wizard/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/accounting/tsconfig.json b/accounting/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/accounting/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/ace/tsconfig.json b/ace/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/ace/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/acl/tsconfig.json b/acl/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/acl/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/acorn/tsconfig.json b/acorn/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/acorn/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/adal/tsconfig.json b/adal/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/adal/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/add2home/tsconfig.json b/add2home/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/add2home/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/adm-zip/tsconfig.json b/adm-zip/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/adm-zip/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/ag-grid/tsconfig.json b/ag-grid/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/ag-grid/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/agenda/tsconfig.json b/agenda/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/agenda/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/alertify/tsconfig.json b/alertify/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/alertify/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/alt/tsconfig.json b/alt/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/alt/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/amazon-product-api/tsconfig.json b/amazon-product-api/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/amazon-product-api/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/amcharts/tsconfig.json b/amcharts/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/amcharts/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/amplify-deferred/tsconfig.json b/amplify-deferred/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/amplify-deferred/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/amplify/tsconfig.json b/amplify/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/amplify/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/amqp-rpc/tsconfig.json b/amqp-rpc/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/amqp-rpc/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/amqplib/tsconfig.json b/amqplib/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/amqplib/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/analytics-node/tsconfig.json b/analytics-node/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/analytics-node/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-agility/tsconfig.json b/angular-agility/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-agility/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-bootstrap-calendar/tsconfig.json b/angular-bootstrap-calendar/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-bootstrap-calendar/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-bootstrap-lightbox/tsconfig.json b/angular-bootstrap-lightbox/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-bootstrap-lightbox/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-breadcrumb/tsconfig.json b/angular-breadcrumb/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-breadcrumb/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-cookie/tsconfig.json b/angular-cookie/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-cookie/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-dialog-service/tsconfig.json b/angular-dialog-service/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-dialog-service/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-dynamic-locale/tsconfig.json b/angular-dynamic-locale/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-dynamic-locale/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-environment/tsconfig.json b/angular-environment/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-environment/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-file-upload/tsconfig.json b/angular-file-upload/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-file-upload/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-formly/tsconfig.json b/angular-formly/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-formly/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-fullscreen/tsconfig.json b/angular-fullscreen/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-fullscreen/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-gettext/tsconfig.json b/angular-gettext/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-gettext/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-google-analytics/tsconfig.json b/angular-google-analytics/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-google-analytics/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-growl-v2/tsconfig.json b/angular-growl-v2/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-growl-v2/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-hotkeys/tsconfig.json b/angular-hotkeys/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-hotkeys/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-http-auth/tsconfig.json b/angular-http-auth/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-http-auth/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-httpi/tsconfig.json b/angular-httpi/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-httpi/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-idle/tsconfig.json b/angular-idle/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-idle/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-jwt/angular-jwt-tests.ts b/angular-jwt/angular-jwt-tests.ts
index 041744f2f6..8ddeb21616 100644
--- a/angular-jwt/angular-jwt-tests.ts
+++ b/angular-jwt/angular-jwt-tests.ts
@@ -3,14 +3,14 @@
var app = angular.module("angular-jwt-tests", ["angular-jwt"]);
-var $jwtHelper: angular.jwt.IJwtHelper;
+var $jwtHelper: ng.jwt.IJwtHelper;
var expToken = 'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwczovL3NhbXBsZXMuYXV0aDAuY29tLyIsInN1YiI6ImZhY2Vib29rfDEwMTU0Mjg3MDI3NTEwMzAyIiwiYXVkIjoiQlVJSlNXOXg2MHNJSEJ3OEtkOUVtQ2JqOGVESUZ4REMiLCJleHAiOjE0MTIyMzQ3MzAsImlhdCI6MTQxMjE5ODczMH0.7M5sAV50fF1-_h9qVbdSgqAnXVF7mz3I6RjS6JiH0H8';
var tokenPayload = $jwtHelper.decodeToken(expToken);
var date = $jwtHelper.getTokenExpirationDate(expToken);
var bool = $jwtHelper.isTokenExpired(expToken);
-var $jwtInterceptor: angular.jwt.IJwtInterceptor;
+var $jwtInterceptor: ng.jwt.IJwtInterceptor;
$jwtInterceptor.tokenGetter = () => {
return expToken;
diff --git a/angular-jwt/angular-jwt.d.ts b/angular-jwt/angular-jwt.d.ts
index 58657194ec..121bd3bf5d 100644
--- a/angular-jwt/angular-jwt.d.ts
+++ b/angular-jwt/angular-jwt.d.ts
@@ -8,14 +8,14 @@
declare namespace angular.jwt {
interface JwtToken {
- iss: string;
- sub: string;
- aud: string;
- exp: number;
- nbf: number;
- iat: number;
- jti: string;
- unique_name: string;
+ iss?: string;
+ sub?: string;
+ aud?: string;
+ exp?: number;
+ nbf?: number;
+ iat?: number;
+ jti?: string;
+ unique_name?: string;
}
interface IJwtHelper {
diff --git a/angular-jwt/tsconfig.json b/angular-jwt/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-jwt/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-load/tsconfig.json b/angular-load/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-load/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-loading-bar/tsconfig.json b/angular-loading-bar/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-loading-bar/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-local-storage/tsconfig.json b/angular-local-storage/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-local-storage/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-localForage/tsconfig.json b/angular-localForage/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-localForage/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-locker/tsconfig.json b/angular-locker/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-locker/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-material/tsconfig.json b/angular-material/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-material/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-media-queries/tsconfig.json b/angular-media-queries/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-media-queries/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-meteor/tsconfig.json b/angular-meteor/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-meteor/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-modal/tsconfig.json b/angular-modal/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-modal/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-notifications/tsconfig.json b/angular-notifications/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-notifications/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-notify/tsconfig.json b/angular-notify/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-notify/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-odata-resources/tsconfig.json b/angular-odata-resources/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-odata-resources/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-permission/angular-permission-2.3.1-tests.ts b/angular-permission/angular-permission-2.3.1-tests.ts
new file mode 100644
index 0000000000..3753ba9d51
--- /dev/null
+++ b/angular-permission/angular-permission-2.3.1-tests.ts
@@ -0,0 +1,92 @@
+///
+
+import permission = angular.permission;
+
+angular
+ .module('fooModule', ['permission', 'user'])
+ .run(function (PermissionStore: permission.PermissionStore, User: any) {
+ // Define anonymous permission
+ PermissionStore
+ .definePermission('anonymous', function (stateParams) {
+ // If the returned value is *truthy* then the user has the permission, otherwise they don't
+ if (!User) {
+ return true; // Is anonymous
+ }
+ return false;
+ });
+ });
+
+ interface BackendUserService {
+ checkSession(): angular.IPromise;
+ getAccessLevel(): angular.IPromise<{accessLevel: string}>;
+ hasPermissionDefinition(permission: string) : angular.IPromise;
+ }
+
+ angular.module('barModule', ['permission', 'user'])
+ .run(function (PermissionStore: permission.PermissionStore, User: BackendUserService, $q: angular.IQService) {
+ PermissionStore
+ // Define user permission calling back-end
+ .definePermission('user', function (stateParams) {
+ // This time we will return a promise
+ // If the promise *resolves* then the user has the permission, if it *rejects* (you guessed it)
+
+ // Let's assume this returns a promise that resolves or rejects if session is active
+ return User.checkSession();
+ });
+
+ PermissionStore
+ // A different example for admin
+ .definePermission('admin', function (stateParams) {
+ var deferred = $q.defer();
+
+ User.getAccessLevel()
+ .then(function (data) {
+ if (data.accessLevel === 'admin') {
+ deferred.resolve();
+ } else {
+ deferred.reject();
+ }
+ })
+ .catch(function () {
+ // Error with request
+ deferred.reject();
+ });
+
+ return deferred.promise;
+ });
+
+ let arrayOfPermissionNames = ['p1', 'p2'];
+ PermissionStore.defineManyPermissions(arrayOfPermissionNames, function (stateParams: angular.ui.IStateParamsService, permissionName: string) {
+ return User.hasPermissionDefinition(permissionName);
+ });
+
+ PermissionStore.clearStore();
+
+ PermissionStore.removePermissionDefinition('user');
+
+ let permissions: Array = PermissionStore.getStore();
+
+
+ });
+
+angular
+ .module('fooModule', ['permission', 'user'])
+ .run(function (RoleStore: permission.RoleStore, User: any) {
+ RoleStore
+ // Permission array validated role
+ // Library will internally validate if 'user' and 'editor' permissions are valid when checking if role is valid
+ .defineRole('admin', ['user', 'editor']);
+
+ RoleStore
+ // Server side validated role
+ .defineRole('accountant', [], function (stateParams) {
+ // Let's assume that we are making a request to server here and return response as promise
+ return User.hasRole('accountant');
+ });
+
+ RoleStore.clearStore();
+
+ RoleStore.removeRoleDefinition('user');
+
+ let roles: Array = RoleStore.getStore();
+ });
diff --git a/angular-permission/angular-permission-2.3.1.d.ts b/angular-permission/angular-permission-2.3.1.d.ts
new file mode 100644
index 0000000000..afe32ce875
--- /dev/null
+++ b/angular-permission/angular-permission-2.3.1.d.ts
@@ -0,0 +1,165 @@
+// Type definitions for angular-permission 2.3.1
+// Project: https://github.com/Narzerus/angular-permission
+// Definitions by: Voislav Mishevski
+// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
+
+///
+///
+
+declare namespace angular.permission {
+
+ export interface PermissionStore {
+ /**
+ * Allows to define permission on application configuration
+ * @method
+ *
+ * @param permissionName {String} Name of defined permission
+ * @param validationFunction {Function} Function used to validate if permission is valid
+ */
+ definePermission(
+ name: string,
+ validationFunction: (stateParams?: angular.ui.IStateParamsService, permission?: string) => boolean | angular.IPromise
+ ): void;
+
+ /**
+ * Allows to define set of permissionNames with shared validation function on application configuration
+ * @method
+ * @throws {TypeError}
+ *
+ * @param permissionNames {Array} Set of permission names
+ * @param validationFunction {Function} Function used to validate if permission is valid
+ */
+ defineManyPermissions(
+ permissions: string[],
+ validationFunction: (stateParams?: angular.ui.IStateParamsService, permission?: string) => boolean | angular.IPromise
+ ): void;
+
+ clearStore(): void;
+
+ /**
+ * Deletes permission
+ * @method
+ *
+ * @param permissionName {String} Name of defined permission
+ */
+ removePermissionDefinition(permission: string): void;
+
+ /**
+ * Checks if permission exists
+ * @method
+ *
+ * @param permissionName {String} Name of defined permission
+ * @returns {Boolean}
+ */
+ hasPermissionDefinition(permissionName: string): boolean;
+
+ /**
+ * Returns all permissions
+ * @method
+ *
+ * @returns {Object} Permissions collection
+ */
+ getStore(): Permission[];
+ }
+
+ export interface RoleStore {
+ /**
+ * Allows to define role
+ * @method
+ *
+ * @param roleName {String} Name of defined role
+ * @param permissions {Array} Set of permission names
+ * @param [validationFunction] {Function} Function used to validate if permissions in role are valid
+ */
+ defineRole(
+ role: string,
+ permissions: Array,
+ validationFunction: RoleValidationFunction
+ ): void;
+
+ /**
+ * Allows to define role
+ * @method
+ *
+ * @param roleName {String} Name of defined role
+ * @param permissions {Array} Set of permission names
+ */
+ defineRole(role: string, permissions: Array): void;
+
+ /**
+ * Checks if role is defined in store
+ * @method
+ *
+ * @param roleName {String} Name of role
+ * @returns {Boolean}
+ */
+ hasRoleDefinition(role: string): boolean;
+
+ /**
+ * Returns role definition object by it's name
+ * @method
+ *
+ * @returns {permission.Role} Role definition object
+ */
+ getRoleDefinition(roleName: string): Role;
+
+ /**
+ * Removes all role definitions
+ * @method
+ */
+ clearStore(): void;
+
+ /**
+ * Deletes role from store
+ * @method
+ *
+ * @param roleName {String} Name of defined permission
+ */
+ removeRoleDefinition(roleName: string): void;
+
+ /**
+ * Returns all role definitions
+ * @method
+ *
+ * @returns {Object} Defined roles collection
+ */
+ getStore(): Role[];
+ }
+
+ export interface Role {
+ roleName: string;
+ permissionNames: string[];
+ validationFunction?: RoleValidationFunction;
+ }
+
+ export interface Permission {
+ permissionName: string;
+ validationFunction?: PermissionValidationFunction;
+ }
+
+ interface RoleValidationFunction {
+ (stateParams?: angular.ui.IStateParamsService, permission?: string): boolean | angular.IPromise;
+ }
+
+ interface PermissionValidationFunction {
+ (stateParams?: angular.ui.IStateParamsService, permission?: string): boolean | angular.IPromise;
+ }
+
+ export interface IPermissionState extends angular.ui.IState {
+ data?: any | DataWithPermissions;
+ }
+
+ export interface DataWithPermissions {
+ permissions?: {
+ only?: (() => void) | Array | angular.IPromise;
+ except?: (() => void) | Array | angular.IPromise;
+ redirectTo: string | (() => string) | (() => PermissionRedirectConfigation) | {[index: string]: PermissionRedirectConfigation}
+ };
+ }
+
+ export interface PermissionRedirectConfigation {
+ state: string;
+ params?: {};
+ options?: angular.ui.IStateOptions;
+ }
+}
diff --git a/angular-permission/angular-permission-tests.ts b/angular-permission/angular-permission-tests.ts
index 206850ad70..cc9cd7c367 100644
--- a/angular-permission/angular-permission-tests.ts
+++ b/angular-permission/angular-permission-tests.ts
@@ -36,7 +36,7 @@ angular
PermissionStore
// A different example for admin
- .definePermission('admin', function (stateParams) {
+ .definePermission('admin', function (permission: string, stateParams: angular.permission.TransitionProperties) {
var deferred = $q.defer();
User.getAccessLevel()
@@ -56,7 +56,7 @@ angular
});
let arrayOfPermissionNames = ['p1', 'p2'];
- PermissionStore.defineManyPermissions(arrayOfPermissionNames, function (stateParams: angular.ui.IStateParamsService, permissionName: string) {
+ PermissionStore.defineManyPermissions(arrayOfPermissionNames, function (permissionName: string, stateParams: angular.permission.TransitionProperties) {
return User.hasPermissionDefinition(permissionName);
});
@@ -79,7 +79,7 @@ angular
RoleStore
// Server side validated role
- .defineRole('accountant', [], function (stateParams) {
+ .defineRole('accountant', [], function (permission, stateParams) {
// Let's assume that we are making a request to server here and return response as promise
return User.hasRole('accountant');
});
diff --git a/angular-permission/angular-permission.d.ts b/angular-permission/angular-permission.d.ts
index 2987aeeb93..6e1dcebf0a 100644
--- a/angular-permission/angular-permission.d.ts
+++ b/angular-permission/angular-permission.d.ts
@@ -1,4 +1,4 @@
-// Type definitions for angular-permission 2.3.1
+// Type definitions for angular-permission 2.3.6
// Project: https://github.com/Narzerus/angular-permission
// Definitions by: Voislav Mishevski
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
@@ -7,6 +7,16 @@
///
declare namespace angular.permission {
+ /**
+ * Used as optional parameter provided on definitions of permissions and roles
+ */
+ export interface TransitionProperties {
+ fromState?: angular.ui.IState;
+ fromParams?: angular.ui.IStateParamsService;
+ toState?: angular.ui.IState;
+ toParams?: angular.ui.IStateParamsService;
+ options?: angular.ui.IStateOptions;
+ }
export interface PermissionStore {
/**
@@ -18,7 +28,7 @@ declare namespace angular.permission {
*/
definePermission(
name: string,
- validationFunction: (stateParams?: angular.ui.IStateParamsService, permission?: string) => boolean | angular.IPromise
+ validationFunction: (permission?: string, transitionProperties?: TransitionProperties) => boolean | angular.IPromise
): void;
/**
@@ -31,7 +41,7 @@ declare namespace angular.permission {
*/
defineManyPermissions(
permissions: string[],
- validationFunction: (stateParams?: angular.ui.IStateParamsService, permission?: string) => boolean | angular.IPromise
+ validationFunction: (permission?: string, transitionProperties?: TransitionProperties) => boolean | angular.IPromise
): void;
clearStore(): void;
@@ -138,11 +148,11 @@ declare namespace angular.permission {
}
interface RoleValidationFunction {
- (stateParams?: angular.ui.IStateParamsService, permission?: string): boolean | angular.IPromise;
+ (permission?: string, transitionProperties?: TransitionProperties): boolean | angular.IPromise;
}
interface PermissionValidationFunction {
- (stateParams?: angular.ui.IStateParamsService, permission?: string): boolean | angular.IPromise;
+ (permission?: string, transitionProperties?: TransitionProperties): boolean | angular.IPromise;
}
export interface IPermissionState extends angular.ui.IState {
diff --git a/angular-permission/tsconfig.json b/angular-permission/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-permission/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-scenario/tsconfig.json b/angular-scenario/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-scenario/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-scroll/tsconfig.json b/angular-scroll/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-scroll/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-signalr-hub/tsconfig.json b/angular-signalr-hub/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-signalr-hub/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-spinner/tsconfig.json b/angular-spinner/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-spinner/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-storage/tsconfig.json b/angular-storage/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-storage/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-strap/tsconfig.json b/angular-strap/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-strap/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-toastr/tsconfig.json b/angular-toastr/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-toastr/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-toasty/tsconfig.json b/angular-toasty/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-toasty/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-touchspin/tsconfig.json b/angular-touchspin/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-touchspin/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-translate/angular-translate-tests.ts b/angular-translate/angular-translate-tests.ts
index 8ef1ab2e39..4aac8b4b34 100644
--- a/angular-translate/angular-translate-tests.ts
+++ b/angular-translate/angular-translate-tests.ts
@@ -35,7 +35,11 @@ interface Scope extends ng.IScope {
app.controller('Ctrl', ($scope: Scope, $translate: angular.translate.ITranslateService) => {
$scope['changeLanguage'] = function (key: any) {
- $translate.use(key);
+ $translate.onReady().then(() => {
+ if($translate.isReady()) {
+ $translate.use(key);
+ }
+ });
};
}).run(($filter: ng.IFilterService) => {
var x: string;
diff --git a/angular-translate/angular-translate.d.ts b/angular-translate/angular-translate.d.ts
index ea905a210e..2c1dc4e2be 100644
--- a/angular-translate/angular-translate.d.ts
+++ b/angular-translate/angular-translate.d.ts
@@ -66,6 +66,8 @@ declare namespace angular.translate {
useFallbackLanguage(langKey?: string): void;
versionInfo(): string;
loaderCache(): any;
+ isReady(): boolean;
+ onReady(): angular.IPromise;
}
interface ITranslateProvider extends angular.IServiceProvider {
diff --git a/angular-translate/tsconfig.json b/angular-translate/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-translate/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-ui-bootstrap/tsconfig.json b/angular-ui-bootstrap/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-ui-bootstrap/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-ui-router/tsconfig.json b/angular-ui-router/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-ui-router/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-ui-scroll/tsconfig.json b/angular-ui-scroll/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-ui-scroll/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-ui-sortable/tsconfig.json b/angular-ui-sortable/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-ui-sortable/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-ui-tree/tsconfig.json b/angular-ui-tree/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-ui-tree/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular-wizard/tsconfig.json b/angular-wizard/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular-wizard/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angular.throttle/tsconfig.json b/angular.throttle/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angular.throttle/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angularLocalStorage/tsconfig.json b/angularLocalStorage/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angularLocalStorage/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angularfire/tsconfig.json b/angularfire/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angularfire/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angularjs/angular-mocks-tests.ts b/angularjs/angular-mocks-tests.ts
index 294bcf8982..8790e68cf3 100644
--- a/angularjs/angular-mocks-tests.ts
+++ b/angularjs/angular-mocks-tests.ts
@@ -36,6 +36,7 @@ mock.module(
function () { return 2; }
);
mock.module({ module1: function () { return 1; } });
+mock.module.sharedInjector();
date = mock.TzDate(-7, '2013-1-1T15:00:00Z');
date = mock.TzDate(-8, 12345678);
diff --git a/angularjs/angular-mocks.d.ts b/angularjs/angular-mocks.d.ts
index c97471e5bf..9031cc56d1 100644
--- a/angularjs/angular-mocks.d.ts
+++ b/angularjs/angular-mocks.d.ts
@@ -47,7 +47,10 @@ declare namespace angular {
inject: IInjectStatic
// see https://docs.angularjs.org/api/ngMock/function/angular.mock.module
- module(...modules: any[]): any;
+ module: {
+ (...modules: any[]): any;
+ sharedInjector(): void;
+ }
// see https://docs.angularjs.org/api/ngMock/type/angular.mock.TzDate
TzDate(offset: number, timestamp: number): Date;
diff --git a/angularjs/tsconfig.json b/angularjs/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angularjs/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/angulartics/tsconfig.json b/angulartics/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/angulartics/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/animation-frame/tsconfig.json b/animation-frame/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/animation-frame/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/ansi-styles/tsconfig.json b/ansi-styles/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/ansi-styles/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/ansicolors/tsconfig.json b/ansicolors/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/ansicolors/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/antd/tsconfig.json b/antd/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/antd/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/any-db-transaction/tsconfig.json b/any-db-transaction/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/any-db-transaction/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/any-db/tsconfig.json b/any-db/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/any-db/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/anydb-sql-migrations/tsconfig.json b/anydb-sql-migrations/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/anydb-sql-migrations/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/anydb-sql/tsconfig.json b/anydb-sql/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/anydb-sql/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/api-error-handler/tsconfig.json b/api-error-handler/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/api-error-handler/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/apn/tsconfig.json b/apn/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/apn/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/appframework/tsconfig.json b/appframework/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/appframework/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/appletvjs/tsconfig.json b/appletvjs/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/appletvjs/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/applicationinsights/tsconfig.json b/applicationinsights/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/applicationinsights/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/arbiter/tsconfig.json b/arbiter/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/arbiter/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/arcgis-js-api/tsconfig.json b/arcgis-js-api/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/arcgis-js-api/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/archiver/tsconfig.json b/archiver/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/archiver/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/archy/tsconfig.json b/archy/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/archy/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/argparse/tsconfig.json b/argparse/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/argparse/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/asana/tsconfig.json b/asana/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/asana/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/asciify/tsconfig.json b/asciify/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/asciify/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/aspnet-identity-pw/tsconfig.json b/aspnet-identity-pw/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/aspnet-identity-pw/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/assert/tsconfig.json b/assert/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/assert/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/assertion-error/tsconfig.json b/assertion-error/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/assertion-error/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/assertsharp/tsconfig.json b/assertsharp/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/assertsharp/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/async-lock/tsconfig.json b/async-lock/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/async-lock/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/async-writer/tsconfig.json b/async-writer/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/async-writer/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/async/tsconfig.json b/async/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/async/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/asyncblock/tsconfig.json b/asyncblock/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/asyncblock/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/atmosphere/tsconfig.json b/atmosphere/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/atmosphere/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/atom-keymap/tsconfig.json b/atom-keymap/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/atom-keymap/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/atom/tsconfig.json b/atom/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/atom/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/atpl/tsconfig.json b/atpl/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/atpl/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/auth0-angular/tsconfig.json b/auth0-angular/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/auth0-angular/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/auth0-lock/tsconfig.json b/auth0-lock/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/auth0-lock/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/auth0.widget/tsconfig.json b/auth0.widget/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/auth0.widget/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/auth0/tsconfig.json b/auth0/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/auth0/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/auto-launch/tsconfig.json b/auto-launch/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/auto-launch/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/autobahn/tsconfig.json b/autobahn/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/autobahn/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/autolinker/tsconfig.json b/autolinker/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/autolinker/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/autoprefixer-core/tsconfig.json b/autoprefixer-core/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/autoprefixer-core/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/aws-sdk/tsconfig.json b/aws-sdk/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/aws-sdk/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/axios/tsconfig.json b/axios/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/axios/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/azure-mobile-apps/tsconfig.json b/azure-mobile-apps/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/azure-mobile-apps/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/azure-mobile-services-client/tsconfig.json b/azure-mobile-services-client/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/azure-mobile-services-client/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/azure-sb/tsconfig.json b/azure-sb/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/azure-sb/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/azure/tsconfig.json b/azure/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/azure/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/babel-core/babel-core-tests.ts b/babel-core/babel-core-tests.ts
new file mode 100644
index 0000000000..e564b9d81e
--- /dev/null
+++ b/babel-core/babel-core-tests.ts
@@ -0,0 +1,32 @@
+///
+import * as babel from "babel-core";
+
+
+// Example from https://github.com/babel/babel/tree/master/packages/babel-core
+const code = `class Example {}`;
+const result = babel.transform(code, { /* options */ });
+result.code; // Generated code
+result.map; // Sourcemap
+result.ast; // AST
+
+
+// Examples from http://babeljs.io/docs/usage/api/
+let options: babel.TransformOptions = {
+ plugins: [
+ "es2015-arrow-functions",
+ "es2015-block-scoped-functions",
+ "es2015-block-scoping",
+ "es2015-classes",
+ ],
+ only: /.*\.js/,
+ ast: false,
+ sourceMaps: true
+};
+
+babel.transformFile("filename.js", options, function (err, result) {
+ result.code;
+ result.map;
+ result.ast;
+});
+
+babel.transformFileSync("filename.js", options).code;
diff --git a/babel-core/babel-core.d.ts b/babel-core/babel-core.d.ts
new file mode 100644
index 0000000000..19146e65e0
--- /dev/null
+++ b/babel-core/babel-core.d.ts
@@ -0,0 +1,144 @@
+// Type definitions for babel-core v6.7
+// Project: https://github.com/babel/babel/tree/master/packages/babel-core
+// Definitions by: Troy Gerwien
+// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
+
+///
+///
+///
+
+declare module "babel-core" {
+ import * as t from 'babel-types';
+ export {t as types};
+ type Node = t.Node;
+ export import template = require('babel-template');
+ export var version: string;
+ import traverse, {Visitor} from "babel-traverse";
+ export {traverse, Visitor};
+
+
+ /** Transforms the passed in `code`. Returning an object with the generated code, source map, and AST. */
+ export function transform(code: string, opts?: TransformOptions): BabelFileResult;
+
+ /** Asynchronously transforms the entire contents of a file. */
+ export function transformFile(filename: string, opts: TransformOptions, callback: (err: any, result: BabelFileResult) => void): void;
+
+ /** Synchronous version of `babel.transformFile`. Returns the transformed contents of the `filename`. */
+ export function transformFileSync(filename: string, opts?: TransformOptions): BabelFileResult;
+
+ export function transformFromAst(ast: Node, code?: string, opts?: TransformOptions): BabelFileResult;
+
+ export interface TransformOptions {
+
+ /** Filename to use when reading from stdin - this will be used in source-maps, errors etc. Default: "unknown". */
+ filename?: string;
+
+ /** Filename relative to `sourceRoot`. */
+ filenameRelative?: string;
+
+ /** A source map object that the output source map will be based on. */
+ inputSourceMap?: Object;
+
+ /**
+ * This is an object of keys that represent different environments. For example, you may have:
+ * `{ env: { production: { / * specific options * / } } }`
+ * which will use those options when the enviroment variable `BABEL_ENV` is set to `"production"`.
+ * If `BABEL_ENV` isn't set then `NODE_ENV` will be used, if it's not set then it defaults to `"development"`.
+ */
+ env?: Object;
+
+ /** Retain line numbers - will result in really ugly code. Default: `false` */
+ retainLines?: boolean;
+
+ /** Enable/disable ANSI syntax highlighting of code frames. Default: `true`. */
+ highlightCode?: boolean;
+
+ /** List of presets (a set of plugins) to load and use. */
+ presets?: any[];
+
+ /** List of plugins to load and use. */
+ plugins?: any[];
+
+ /** list of glob paths to **not** compile. Opposite to the `only` option. */
+ ignore?: string[];
+
+ /**
+ * A glob, regex, or mixed array of both, matching paths to only compile. Can also be an array of arrays containing
+ * paths to explicitly match. When attempting to compile a non-matching file it's returned verbatim.
+ */
+ only?: string | RegExp | Array;
+
+ /** Enable code generation. Default: `true`. */
+ code?: boolean;
+
+ /** Include the AST in the returned object. Default: `true`. */
+ ast?: boolean;
+
+ /** A path to an .babelrc file to extend. */
+ extends?: string;
+
+ /** write comments to generated output. Default: `true`. */
+ comments?: boolean;
+
+ /**
+ * An optional callback that controls whether a comment should be output or not. Called as
+ * `shouldPrintComment(commentContents)`. **NOTE**: This overrides the `comments` option when used.
+ */
+ shouldPrintComment?: (comment: string) => boolean;
+
+ /**
+ * Do not include superfluous whitespace characters and line terminators. When set to `"auto"`, `compact` is set to
+ * `true` on input sizes of >100KB.
+ */
+ compact?: boolean | "auto";
+
+ /**
+ * If truthy, adds a `map` property to returned output. If set to `"inline"`, a comment with a `sourceMappingURL`
+ * directive is added to the bottom of the returned code. If set to `"both"` then a map property is returned as well
+ * as a source map comment appended.
+ */
+ sourceMaps?: boolean | "inline" | "both";
+
+ /** Set `file` on returned source map. */
+ sourceMapTarget?: string;
+
+ /** Set `sources[0]` on returned source map. */
+ sourceFileName?: string;
+
+ /** The root from which all sources are relative. */
+ sourceRoot?: string;
+
+ /** Specify whether or not to use `.babelrc` and `.babelignore` files. Default: `true`. */
+ babelrc?: boolean;
+
+ /** Attach a comment before all non-user injected code. */
+ auxiliaryCommentBefore?: string;
+
+ /** Attach a comment after all non-user injected code. */
+ auxiliaryCommentAfter?: string;
+
+ /**
+ * Specify a custom callback to generate a module id with. Called as `getModuleId(moduleName)`.
+ * If falsy value is returned then the generated module id is used.
+ */
+ getModuleId?: (moduleName: string) => string;
+
+ /** Optional prefix for the AMD module formatter that will be prepend to the filename on module definitions. */
+ moduleRoot?: string;
+
+ /**
+ * If truthy, insert an explicit id for modules. By default, all modules are anonymous.
+ * (Not available for `common` modules).
+ */
+ moduleIds?: boolean;
+
+ /** Specify a custom name for module ids. */
+ moduleId?: string;
+ }
+
+ export interface BabelFileResult {
+ ast?: Node;
+ code?: string;
+ map?: Object;
+ }
+}
diff --git a/babel-core/tsconfig.json b/babel-core/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/babel-core/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/babel-generator/babel-generator-tests.ts b/babel-generator/babel-generator-tests.ts
new file mode 100644
index 0000000000..33d10b5cd9
--- /dev/null
+++ b/babel-generator/babel-generator-tests.ts
@@ -0,0 +1,27 @@
+///
+///
+
+
+// Example from https://github.com/babel/babel/tree/master/packages/babel-generator
+import {parse} from 'babylon';
+import generate from 'babel-generator';
+
+const code = 'class Example {}';
+const ast = parse(code);
+
+ast.type;
+ast.loc.start;
+
+const output = generate(ast, { /* options */ }, code);
+
+
+// Example from https://github.com/thejameskyle/babel-handbook/blob/master/translations/en/plugin-handbook.md#babel-generator
+let result = generate(ast, {
+ retainLines: false,
+ compact: "auto",
+ concise: false,
+ quotes: "double",
+ // ...
+}, code);
+result.code;
+result.map;
diff --git a/babel-generator/babel-generator.d.ts b/babel-generator/babel-generator.d.ts
new file mode 100644
index 0000000000..aa8232e8b0
--- /dev/null
+++ b/babel-generator/babel-generator.d.ts
@@ -0,0 +1,102 @@
+// Type definitions for babel-generator v6.7
+// Project: https://github.com/babel/babel/tree/master/packages/babel-generator
+// Definitions by: Troy Gerwien
+// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
+
+///
+
+declare module "babel-generator" {
+ import * as t from 'babel-types';
+ type Node = t.Node;
+
+ /**
+ * Turns an AST into code, maintaining sourcemaps, user preferences, and valid output.
+ * @param ast - the abstract syntax tree from which to generate output code.
+ * @param opts - used for specifying options for code generation.
+ * @param code - the original source code, used for source maps.
+ * @returns - an object containing the output code and source map.
+ */
+ export default function generate(ast: Node, opts?: GeneratorOptions, code?: string | {[filename: string]: string}): GeneratorResult;
+
+ export interface GeneratorOptions {
+
+ /**
+ * Optional string to add as a block comment at the start of the output file.
+ */
+ auxiliaryCommentBefore?: string;
+
+ /**
+ * Optional string to add as a block comment at the end of the output file.
+ */
+ auxiliaryCommentAfter?: string;
+
+ /**
+ * Function that takes a comment (as a string) and returns true if the comment should be included in the output.
+ * By default, comments are included if `opts.comments` is `true` or if `opts.minifed` is `false` and the comment
+ * contains `@preserve` or `@license`.
+ */
+ shouldPrintComment?: (comment: string) => boolean;
+
+ /**
+ * Attempt to use the same line numbers in the output code as in the source code (helps preserve stack traces).
+ * Defaults to `false`.
+ */
+ retainLines?: boolean;
+
+ /**
+ * Should comments be included in output? Defaults to `true`.
+ */
+ comments?: boolean;
+
+ /**
+ * Set to true to avoid adding whitespace for formatting. Defaults to the value of `opts.minified`.
+ */
+ compact?: boolean | 'auto';
+
+ /**
+ * Should the output be minified. Defaults to `false`.
+ */
+ minified?: boolean;
+
+ /**
+ * Set to true to reduce whitespace (but not as much as opts.compact). Defaults to `false`.
+ */
+ concise?: boolean;
+
+ /**
+ * The type of quote to use in the output. If omitted, autodetects based on `ast.tokens`.
+ */
+ quotes?: 'single' | 'double';
+
+ /**
+ * Used in warning messages
+ */
+ filename?: string;
+
+ /**
+ * Enable generating source maps. Defaults to `false`.
+ */
+ sourceMaps?: boolean;
+
+ /**
+ * The filename of the generated code that the source map will be associated with.
+ */
+ sourceMapTarget?: string;
+
+ /**
+ * A root for all relative URLs in the source map.
+ */
+ sourceRoot?: string;
+
+ /**
+ * The filename for the source code (i.e. the code in the `code` argument).
+ * This will only be used if `code` is a string.
+ */
+ sourceFileName?: string;
+ }
+
+ export interface GeneratorResult {
+ map: Object;
+ code: string;
+ }
+}
diff --git a/babel-generator/tsconfig.json b/babel-generator/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/babel-generator/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/babel-template/babel-template-tests.ts b/babel-template/babel-template-tests.ts
new file mode 100644
index 0000000000..e0ae7497ff
--- /dev/null
+++ b/babel-template/babel-template-tests.ts
@@ -0,0 +1,21 @@
+///
+///
+///
+
+
+// Example from https://github.com/babel/babel/tree/master/packages/babel-template
+import template = require('babel-template');
+import generate from 'babel-generator';
+import * as t from 'babel-types';
+
+const buildRequire = template(`
+ var IMPORT_NAME = require(SOURCE);
+`);
+
+const ast = buildRequire({
+ IMPORT_NAME: t.identifier('myModule'),
+ SOURCE: t.stringLiteral('my-module')
+});
+
+console.log(generate(ast).code);
+// var myModule = require('my-module');
diff --git a/babel-template/babel-template.d.ts b/babel-template/babel-template.d.ts
new file mode 100644
index 0000000000..7b3cafe7f4
--- /dev/null
+++ b/babel-template/babel-template.d.ts
@@ -0,0 +1,21 @@
+// Type definitions for babel-template v6.7
+// Project: https://github.com/babel/babel/tree/master/packages/babel-template
+// Definitions by: Troy Gerwien
+// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
+
+///
+///
+
+declare module "babel-template" {
+ import {BabylonOptions} from 'babylon';
+ import * as t from 'babel-types';
+ type Node = t.Node;
+
+ // NB: This export doesn't match the handbook example, where `template` is the default export.
+ // But it does match the runtime behaviour (at least at the time of this writing). For some reason,
+ // babel-template/lib/index.js has this line at the bottom: module.exports = exports["default"];
+ export = template;
+ function template(code: string, opts?: BabylonOptions): UseTemplate;
+
+ type UseTemplate = (nodes?: {[placeholder: string]: Node}) => Node;
+}
diff --git a/babel-template/tsconfig.json b/babel-template/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/babel-template/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/babel-traverse/babel-traverse-tests.ts b/babel-traverse/babel-traverse-tests.ts
new file mode 100644
index 0000000000..fba04dfd5d
--- /dev/null
+++ b/babel-traverse/babel-traverse-tests.ts
@@ -0,0 +1,111 @@
+///
+///
+///
+
+
+import * as babylon from "babylon";
+import traverse, {Visitor} from 'babel-traverse';
+import * as t from 'babel-types';
+
+
+// Examples from: https://github.com/thejameskyle/babel-handbook/blob/master/translations/en/plugin-handbook.md
+const MyVisitor: Visitor = {
+ Identifier: {
+ enter() {
+ console.log("Entered!");
+ },
+ exit() {
+ console.log("Exited!");
+ }
+ }
+};
+
+const MyVisitor2: Visitor = {
+ Identifier(path) {
+ console.log("Visiting: " + path.node.name);
+ }
+};
+
+
+// Example from https://github.com/thejameskyle/babel-handbook/blob/master/translations/en/plugin-handbook.md#babel-traverse
+const code = `function square(n) {
+ return n * n;
+}`;
+
+const ast = babylon.parse(code);
+
+traverse(ast, {
+ enter(path) {
+ let node = path.node;
+ if (t.isIdentifier(node) && node.name === "n") {
+ node.name = "x";
+ }
+ }
+});
+
+
+// Examples from https://github.com/thejameskyle/babel-handbook/blob/master/translations/en/plugin-handbook.md#writing-your-first-babel-plugin
+
+const v1: Visitor = {
+
+ BinaryExpression(path) {
+ if (t.isIdentifier(path.node.left)) {
+ // ...
+ }
+ path.replaceWith(
+ t.binaryExpression("**", path.node.left, t.numericLiteral(2))
+ );
+ path.parentPath.replaceWith(
+ t.expressionStatement(t.stringLiteral("Anyway the wind blows, doesn't really matter to me, to me."))
+ );
+ path.parentPath.remove();
+ },
+
+ Identifier(path) {
+ if (path.isReferencedIdentifier()) {
+ // ...
+ }
+ if (t.isReferenced(path.node, path.parent)) {
+ // ...
+ }
+ },
+
+ ReturnStatement(path) {
+ path.replaceWithMultiple([
+ t.expressionStatement(t.stringLiteral("Is this the real life?")),
+ t.expressionStatement(t.stringLiteral("Is this just fantasy?")),
+ t.expressionStatement(t.stringLiteral("(Enjoy singing the rest of the song in your head)")),
+ ]);
+ },
+
+ FunctionDeclaration(path, state) {
+ path.replaceWithSourceString(`function add(a, b) {
+ return a + b;
+ }`);
+
+ path.insertBefore(t.expressionStatement(t.stringLiteral("Because I'm easy come, easy go.")));
+ path.insertAfter(t.expressionStatement(t.stringLiteral("A little high, little low.")));
+ path.remove();
+
+ if (path.scope.hasBinding("n")) {
+ // ...
+ }
+ if (path.scope.hasOwnBinding("n")) {
+ // ...
+ }
+
+ let id1 = path.scope.generateUidIdentifier("uid");
+ id1.type;
+ id1.name;
+ let id2 = path.scope.generateUidIdentifier("uid");
+ id2.type;
+ id2.name;
+
+ const id = path.scope.generateUidIdentifierBasedOnNode(path.node.id);
+ path.remove();
+ path.scope.parent.push({ id, init: path.node });
+
+ path.scope.rename("n", "x");
+ path.scope.rename("n");
+ }
+};
diff --git a/babel-traverse/babel-traverse.d.ts b/babel-traverse/babel-traverse.d.ts
new file mode 100644
index 0000000000..17cbda2f23
--- /dev/null
+++ b/babel-traverse/babel-traverse.d.ts
@@ -0,0 +1,966 @@
+// Type definitions for babel-traverse v6.7
+// Project: https://github.com/babel/babel/tree/master/packages/babel-traverse
+// Definitions by: Troy Gerwien
+// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
+
+///
+
+declare module "babel-traverse" {
+ import * as t from 'babel-types';
+ type Node = t.Node;
+
+ export default function traverse(parent: Node | Node[], opts?: TraverseOptions, scope?: Scope, state?: any, parentPath?: NodePath): void;
+
+ export interface TraverseOptions extends Visitor {
+ scope?: Scope;
+ noScope?: boolean;
+ }
+
+ export class Scope {
+ constructor(path: NodePath, parentScope?: Scope);
+ path: NodePath;
+ block: Node;
+ parentBlock: Node;
+ parent: Scope;
+ hub: Hub;
+ bindings: { [name: string]: Binding; };
+
+ /** Traverse node with current scope and path. */
+ traverse(node: Node | Node[], opts?: TraverseOptions, state?: any): void;
+
+ /** Generate a unique identifier and add it to the current scope. */
+ generateDeclaredUidIdentifier(name?: string): t.Identifier;
+
+ /** Generate a unique identifier. */
+ generateUidIdentifier(name?: string): t.Identifier;
+
+ /** Generate a unique `_id1` binding. */
+ generateUid(name?: string): string;
+
+ /** Generate a unique identifier based on a node. */
+ generateUidIdentifierBasedOnNode(parent: Node, defaultName?: string): t.Identifier;
+
+ /**
+ * Determine whether evaluating the specific input `node` is a consequenceless reference. ie.
+ * evaluating it wont result in potentially arbitrary code from being ran. The following are
+ * whitelisted and determined not to cause side effects:
+ *
+ * - `this` expressions
+ * - `super` expressions
+ * - Bound identifiers
+ */
+ isStatic(node: Node): boolean;
+
+ /** Possibly generate a memoised identifier if it is not static and has consequences. */
+ maybeGenerateMemoised(node: Node, dontPush?: boolean): t.Identifier;
+
+ checkBlockScopedCollisions(local: Node, kind: string, name: string, id: Object): void;
+
+ rename(oldName: string, newName?: string, block?: Node): void;
+
+ dump(): void;
+
+ toArray(node: Node, i?: number): Node;
+
+ registerDeclaration(path: NodePath): void;
+
+ buildUndefinedNode(): Node;
+
+ registerConstantViolation(path: NodePath): void;
+
+ registerBinding(kind: string, path: NodePath, bindingPath?: NodePath): void;
+
+ addGlobal(node: Node): void;
+
+ hasUid(name: string): boolean;
+
+ hasGlobal(name: string): boolean;
+
+ hasReference(name: string): boolean;
+
+ isPure(node: Node, constantsOnly?: boolean): boolean;
+
+ setData(key: string, val: any): any;
+
+ getData(key: string): any;
+
+ removeData(key: string): void;
+
+ push(opts: any): void;
+
+ getProgramParent(): Scope;
+
+ getFunctionParent(): Scope;
+
+ getBlockParent(): Scope;
+
+ /** Walks the scope tree and gathers **all** bindings. */
+ getAllBindings(...kinds: string[]): Object;
+
+ bindingIdentifierEquals(name: string, node: Node): boolean;
+
+ getBinding(name: string): Binding;
+
+ getOwnBinding(name: string): Binding;
+
+ getBindingIdentifier(name: string): t.Identifier;
+
+ getOwnBindingIdentifier(name: string): t.Identifier;
+
+ hasOwnBinding(name: string): boolean;
+
+ hasBinding(name: string, noGlobals?: boolean): boolean;
+
+ parentHasBinding(name: string, noGlobals?: boolean): boolean;
+
+ /** Move a binding of `name` to another `scope`. */
+ moveBindingTo(name: string, scope: Scope): void;
+
+ removeOwnBinding(name: string): void;
+
+ removeBinding(name: string): void;
+ }
+
+ export class Binding {
+ constructor(opts: { existing: Binding; identifier: t.Identifier; scope: Scope; path: NodePath; kind: 'var' | 'let' | 'const'; });
+ identifier: t.Identifier;
+ scope: Scope;
+ path: NodePath;
+ kind: 'var' | 'let' | 'const';
+ referenced: boolean;
+ references: number;
+ referencePaths: NodePath[];
+ constant: boolean;
+ constantViolations: NodePath[];
+ }
+
+ export interface Visitor extends VisitNodeObject {
+ ArrayExpression?: VisitNode;
+ AssignmentExpression?: VisitNode;
+ LVal?: VisitNode;
+ Expression?: VisitNode;
+ BinaryExpression?: VisitNode;
+ Directive?: VisitNode;
+ DirectiveLiteral?: VisitNode;
+ BlockStatement?: VisitNode;
+ BreakStatement?: VisitNode;
+ Identifier?: VisitNode;
+ CallExpression?: VisitNode;
+ CatchClause?: VisitNode;
+ ConditionalExpression?: VisitNode;
+ ContinueStatement?: VisitNode;
+ DebuggerStatement?: VisitNode;
+ DoWhileStatement?: VisitNode;
+ Statement?: VisitNode;
+ EmptyStatement?: VisitNode;
+ ExpressionStatement?: VisitNode;
+ File?: VisitNode;
+ Program?: VisitNode;
+ ForInStatement?: VisitNode;
+ VariableDeclaration?: VisitNode;
+ ForStatement?: VisitNode;
+ FunctionDeclaration?: VisitNode;
+ FunctionExpression?: VisitNode;
+ IfStatement?: VisitNode;
+ LabeledStatement?: VisitNode;
+ StringLiteral?: VisitNode;
+ NumericLiteral?: VisitNode;
+ NullLiteral?: VisitNode;
+ BooleanLiteral?: VisitNode;
+ RegExpLiteral?: VisitNode;
+ LogicalExpression?: VisitNode;
+ MemberExpression?: VisitNode;
+ NewExpression?: VisitNode;
+ ObjectExpression?: VisitNode;
+ ObjectMethod?: VisitNode;
+ ObjectProperty?: VisitNode;
+ RestElement?: VisitNode;
+ ReturnStatement?: VisitNode;
+ SequenceExpression?: VisitNode;
+ SwitchCase?: VisitNode;
+ SwitchStatement?: VisitNode;
+ ThisExpression?: VisitNode;
+ ThrowStatement?: VisitNode;
+ TryStatement?: VisitNode;
+ UnaryExpression?: VisitNode;
+ UpdateExpression?: VisitNode;
+ VariableDeclarator?: VisitNode;
+ WhileStatement?: VisitNode;
+ WithStatement?: VisitNode;
+ AssignmentPattern?: VisitNode;
+ ArrayPattern?: VisitNode;
+ ArrowFunctionExpression?: VisitNode;
+ ClassBody?: VisitNode;
+ ClassDeclaration?: VisitNode;
+ ClassExpression?: VisitNode;
+ ExportAllDeclaration?: VisitNode;
+ ExportDefaultDeclaration?: VisitNode;
+ ExportNamedDeclaration?: VisitNode;
+ Declaration?: VisitNode;
+ ExportSpecifier?: VisitNode;
+ ForOfStatement?: VisitNode;
+ ImportDeclaration?: VisitNode;
+ ImportDefaultSpecifier?: VisitNode;
+ ImportNamespaceSpecifier?: VisitNode;
+ ImportSpecifier?: VisitNode;
+ MetaProperty?: VisitNode;
+ ClassMethod?: VisitNode;
+ ObjectPattern?: VisitNode;
+ SpreadElement?: VisitNode;
+ Super?: VisitNode;
+ TaggedTemplateExpression?: VisitNode;
+ TemplateLiteral?: VisitNode;
+ TemplateElement?: VisitNode;
+ YieldExpression?: VisitNode;
+ AnyTypeAnnotation?: VisitNode;
+ ArrayTypeAnnotation?: VisitNode;
+ BooleanTypeAnnotation?: VisitNode;
+ BooleanLiteralTypeAnnotation?: VisitNode;
+ NullLiteralTypeAnnotation?: VisitNode;
+ ClassImplements?: VisitNode;
+ ClassProperty?: VisitNode;
+ DeclareClass?: VisitNode;
+ DeclareFunction?: VisitNode;
+ DeclareInterface?: VisitNode;
+ DeclareModule?: VisitNode;
+ DeclareTypeAlias?: VisitNode;
+ DeclareVariable?: VisitNode;
+ ExistentialTypeParam?: VisitNode;
+ FunctionTypeAnnotation?: VisitNode;
+ FunctionTypeParam?: VisitNode;
+ GenericTypeAnnotation?: VisitNode;
+ InterfaceExtends?: VisitNode;
+ InterfaceDeclaration?: VisitNode;
+ IntersectionTypeAnnotation?: VisitNode;
+ MixedTypeAnnotation?: VisitNode;
+ NullableTypeAnnotation?: VisitNode;
+ NumericLiteralTypeAnnotation?: VisitNode;
+ NumberTypeAnnotation?: VisitNode;
+ StringLiteralTypeAnnotation?: VisitNode;
+ StringTypeAnnotation?: VisitNode;
+ ThisTypeAnnotation?: VisitNode;
+ TupleTypeAnnotation?: VisitNode;
+ TypeofTypeAnnotation?: VisitNode;
+ TypeAlias?: VisitNode;
+ TypeAnnotation?: VisitNode;
+ TypeCastExpression?: VisitNode;
+ TypeParameterDeclaration?: VisitNode;
+ TypeParameterInstantiation?: VisitNode;
+ ObjectTypeAnnotation?: VisitNode;
+ ObjectTypeCallProperty?: VisitNode;
+ ObjectTypeIndexer?: VisitNode;
+ ObjectTypeProperty?: VisitNode;
+ QualifiedTypeIdentifier?: VisitNode;
+ UnionTypeAnnotation?: VisitNode;
+ VoidTypeAnnotation?: VisitNode;
+ JSXAttribute?: VisitNode;
+ JSXIdentifier?: VisitNode;
+ JSXNamespacedName?: VisitNode;
+ JSXElement?: VisitNode;
+ JSXExpressionContainer?: VisitNode;
+ JSXClosingElement?: VisitNode;
+ JSXMemberExpression?: VisitNode;
+ JSXOpeningElement?: VisitNode;
+ JSXEmptyExpression?: VisitNode;
+ JSXSpreadAttribute?: VisitNode;
+ JSXText?: VisitNode;
+ Noop?: VisitNode;
+ ParenthesizedExpression?: VisitNode;
+ AwaitExpression?: VisitNode;
+ BindExpression?: VisitNode;
+ Decorator?: VisitNode;
+ DoExpression?: VisitNode;
+ ExportDefaultSpecifier?: VisitNode;
+ ExportNamespaceSpecifier?: VisitNode;
+ RestProperty?: VisitNode;
+ SpreadProperty?: VisitNode;
+ Binary?: VisitNode;
+ Scopable?: VisitNode;
+ BlockParent?: VisitNode;
+ Block?: VisitNode;
+ Terminatorless?: VisitNode;
+ CompletionStatement?: VisitNode;
+ Conditional?: VisitNode;
+ Loop?: VisitNode;
+ While?: VisitNode;
+ ExpressionWrapper?: VisitNode;
+ For?: VisitNode;
+ ForXStatement?: VisitNode;
+ Function?: VisitNode;
+ FunctionParent?: VisitNode;
+ Pureish?: VisitNode;
+ Literal?: VisitNode;
+ Immutable?: VisitNode;
+ UserWhitespacable?: VisitNode;
+ Method?: VisitNode;
+ ObjectMember?: VisitNode;
+ Property?: VisitNode;
+ UnaryLike?: VisitNode;
+ Pattern?: VisitNode;
+ Class?: VisitNode;
+ ModuleDeclaration?: VisitNode;
+ ExportDeclaration?: VisitNode;
+ ModuleSpecifier?: VisitNode;
+ Flow?: VisitNode;
+ FlowBaseAnnotation?: VisitNode;
+ FlowDeclaration?: VisitNode;
+ JSX?: VisitNode;
+ }
+
+ export type VisitNode = VisitNodeFunction | VisitNodeObject;
+
+ export type VisitNodeFunction = (path: NodePath, state: any) => void;
+
+ export interface VisitNodeObject {
+ enter?(path: NodePath, state: any): void;
+ exit?(path: NodePath, state: any): void;
+ }
+
+ export class NodePath {
+ constructor(hub: Hub, parent: Node);
+ parent: Node;
+ hub: Hub;
+ contexts: TraversalContext[];
+ data: Object;
+ shouldSkip: boolean;
+ shouldStop: boolean;
+ removed: boolean;
+ state: any;
+ opts: Object;
+ skipKeys: Object;
+ parentPath: NodePath;
+ context: TraversalContext;
+ container: Object | Object[];
+ listKey: string;
+ inList: boolean;
+ parentKey: string;
+ key: string;
+ node: T;
+ scope: Scope;
+ type: string;
+ typeAnnotation: Object;
+
+ getScope(scope: Scope): Scope;
+
+ setData(key: string, val: any): any;
+
+ getData(key: string, def?: any): any;
+
+ buildCodeFrameError(msg: string, Error: Error): Error;
+
+ traverse(visitor: Visitor, state?: any): void;
+
+ set(key: string, node: Node): void;
+
+ getPathLocation(): string;
+
+ debug(buildMessage: Function): void;
+
+ // ------------------------- ancestry -------------------------
+ /**
+ * Call the provided `callback` with the `NodePath`s of all the parents.
+ * When the `callback` returns a truthy value, we return that node path.
+ */
+ findParent(callback: (path: NodePath) => boolean): NodePath;
+
+ find(callback: (path: NodePath) => boolean): NodePath;
+
+ /** Get the parent function of the current path. */
+ getFunctionParent(): NodePath;
+
+ /** Walk up the tree until we hit a parent node path in a list. */
+ getStatementParent(): NodePath;
+
+ /**
+ * Get the deepest common ancestor and then from it, get the earliest relationship path
+ * to that ancestor.
+ *
+ * Earliest is defined as being "before" all the other nodes in terms of list container
+ * position and visiting key.
+ */
+ getEarliestCommonAncestorFrom(paths: NodePath[]): NodePath;
+
+ /** Get the earliest path in the tree where the provided `paths` intersect. */
+ getDeepestCommonAncestorFrom(paths: NodePath[], filter?: Function): NodePath;
+
+ /**
+ * Build an array of node paths containing the entire ancestry of the current node path.
+ *
+ * NOTE: The current node path is included in this.
+ */
+ getAncestry(): NodePath[];
+
+ inType(...candidateTypes: string[]): boolean;
+
+ // ------------------------- inference -------------------------
+ /** Infer the type of the current `NodePath`. */
+ getTypeAnnotation(): t.FlowTypeAnnotation;
+
+ isBaseType(baseName: string, soft?: boolean): boolean;
+
+ couldBeBaseType(name: string): boolean;
+
+ baseTypeStrictlyMatches(right: NodePath): boolean;
+
+ isGenericType(genericName: string): boolean;
+
+ // ------------------------- replacement -------------------------
+ /**
+ * Replace a node with an array of multiple. This method performs the following steps:
+ *
+ * - Inherit the comments of first provided node with that of the current node.
+ * - Insert the provided nodes after the current node.
+ * - Remove the current node.
+ */
+ replaceWithMultiple(nodes: Node[]): void;
+
+ /**
+ * Parse a string as an expression and replace the current node with the result.
+ *
+ * NOTE: This is typically not a good idea to use. Building source strings when
+ * transforming ASTs is an antipattern and SHOULD NOT be encouraged. Even if it's
+ * easier to use, your transforms will be extremely brittle.
+ */
+ replaceWithSourceString(replacement: any): void;
+
+ /** Replace the current node with another. */
+ replaceWith(replacement: Node | NodePath): void;
+
+ /**
+ * This method takes an array of statements nodes and then explodes it
+ * into expressions. This method retains completion records which is
+ * extremely important to retain original semantics.
+ */
+ replaceExpressionWithStatements(nodes: Node[]): Node;
+
+ replaceInline(nodes: Node | Node[]): void;
+
+ // ------------------------- evaluation -------------------------
+ /**
+ * Walk the input `node` and statically evaluate if it's truthy.
+ *
+ * Returning `true` when we're sure that the expression will evaluate to a
+ * truthy value, `false` if we're sure that it will evaluate to a falsy
+ * value and `undefined` if we aren't sure. Because of this please do not
+ * rely on coercion when using this method and check with === if it's false.
+ */
+ evaluateTruthy(): boolean;
+
+ /**
+ * Walk the input `node` and statically evaluate it.
+ *
+ * Returns an object in the form `{ confident, value }`. `confident` indicates
+ * whether or not we had to drop out of evaluating the expression because of
+ * hitting an unknown node that we couldn't confidently find the value of.
+ *
+ * Example:
+ *
+ * t.evaluate(parse("5 + 5")) // { confident: true, value: 10 }
+ * t.evaluate(parse("!true")) // { confident: true, value: false }
+ * t.evaluate(parse("foo + foo")) // { confident: false, value: undefined }
+ */
+ evaluate(): { confident: boolean; value: any };
+
+ // ------------------------- introspection -------------------------
+ /**
+ * Match the current node if it matches the provided `pattern`.
+ *
+ * For example, given the match `React.createClass` it would match the
+ * parsed nodes of `React.createClass` and `React["createClass"]`.
+ */
+ matchesPattern(pattern: string, allowPartial?: boolean): boolean;
+
+ /**
+ * Check whether we have the input `key`. If the `key` references an array then we check
+ * if the array has any items, otherwise we just check if it's falsy.
+ */
+ has(key: string): boolean;
+
+ isStatic(): boolean;
+
+ /** Alias of `has`. */
+ is(key: string): boolean;
+
+ /** Opposite of `has`. */
+ isnt(key: string): boolean;
+
+ /** Check whether the path node `key` strict equals `value`. */
+ equals(key: string, value: any): boolean;
+
+ /**
+ * Check the type against our stored internal type of the node. This is handy when a node has
+ * been removed yet we still internally know the type and need it to calculate node replacement.
+ */
+ isNodeType(type: string): boolean;
+
+ /**
+ * This checks whether or not we're in one of the following positions:
+ *
+ * for (KEY in right);
+ * for (KEY;;);
+ *
+ * This is because these spots allow VariableDeclarations AND normal expressions so we need
+ * to tell the path replacement that it's ok to replace this with an expression.
+ */
+ canHaveVariableDeclarationOrExpression(): boolean;
+
+ /**
+ * This checks whether we are swapping an arrow function's body between an
+ * expression and a block statement (or vice versa).
+ *
+ * This is because arrow functions may implicitly return an expression, which
+ * is the same as containing a block statement.
+ */
+ canSwapBetweenExpressionAndStatement(replacement: Node): boolean;
+
+ /** Check whether the current path references a completion record */
+ isCompletionRecord(allowInsideFunction?: boolean): boolean;
+
+ /**
+ * Check whether or not the current `key` allows either a single statement or block statement
+ * so we can explode it if necessary.
+ */
+ isStatementOrBlock(): boolean;
+
+ /** Check if the currently assigned path references the `importName` of `moduleSource`. */
+ referencesImport(moduleSource: string, importName: string): boolean;
+
+ /** Get the source code associated with this node. */
+ getSource(): string;
+
+ // ------------------------- context -------------------------
+ call(key: string): boolean;
+
+ isBlacklisted(): boolean;
+
+ visit(): boolean;
+
+ skip(): void;
+
+ skipKey(key: string): void;
+
+ stop(): void;
+
+ setScope(): void;
+
+ setContext(context: TraversalContext): NodePath;
+
+ popContext(): void;
+
+ pushContext(context: TraversalContext): void;
+
+ // ------------------------- removal -------------------------
+ remove(): void;
+
+ // ------------------------- modification -------------------------
+ /** Insert the provided nodes before the current one. */
+ insertBefore(nodes: Node | Node[]): any;
+
+ /**
+ * Insert the provided nodes after the current one. When inserting nodes after an
+ * expression, ensure that the completion record is correct by pushing the current node.
+ */
+ insertAfter(nodes: Node | Node[]): any;
+
+ /** Update all sibling node paths after `fromIndex` by `incrementBy`. */
+ updateSiblingKeys(fromIndex: number, incrementBy: number): void;
+
+ /** Hoist the current node to the highest scope possible and return a UID referencing it. */
+ hoist(scope: Scope): void;
+
+ // ------------------------- family -------------------------
+ getStatementParent(): NodePath;
+
+ getOpposite(): NodePath;
+
+ getCompletionRecords(): NodePath[];
+
+ getSibling(key: string): NodePath;
+
+ get(key: string, context?: boolean | TraversalContext): NodePath;
+
+ getBindingIdentifiers(duplicates?: boolean): Node[];
+
+ getOuterBindingIdentifiers(duplicates?: boolean): Node[];
+
+ // ------------------------- comments -------------------------
+ /** Share comments amongst siblings. */
+ shareCommentsWithSiblings(): void;
+
+ addComment(type: string, content: string, line?: boolean): void;
+
+ /** Give node `comments` of the specified `type`. */
+ addComments(type: string, comments: any[]): void;
+
+ // ------------------------- isXXX -------------------------
+ isArrayExpression(opts?: Object): boolean;
+ isAssignmentExpression(opts?: Object): boolean;
+ isBinaryExpression(opts?: Object): boolean;
+ isDirective(opts?: Object): boolean;
+ isDirectiveLiteral(opts?: Object): boolean;
+ isBlockStatement(opts?: Object): boolean;
+ isBreakStatement(opts?: Object): boolean;
+ isCallExpression(opts?: Object): boolean;
+ isCatchClause(opts?: Object): boolean;
+ isConditionalExpression(opts?: Object): boolean;
+ isContinueStatement(opts?: Object): boolean;
+ isDebuggerStatement(opts?: Object): boolean;
+ isDoWhileStatement(opts?: Object): boolean;
+ isEmptyStatement(opts?: Object): boolean;
+ isExpressionStatement(opts?: Object): boolean;
+ isFile(opts?: Object): boolean;
+ isForInStatement(opts?: Object): boolean;
+ isForStatement(opts?: Object): boolean;
+ isFunctionDeclaration(opts?: Object): boolean;
+ isFunctionExpression(opts?: Object): boolean;
+ isIdentifier(opts?: Object): boolean;
+ isIfStatement(opts?: Object): boolean;
+ isLabeledStatement(opts?: Object): boolean;
+ isStringLiteral(opts?: Object): boolean;
+ isNumericLiteral(opts?: Object): boolean;
+ isNullLiteral(opts?: Object): boolean;
+ isBooleanLiteral(opts?: Object): boolean;
+ isRegExpLiteral(opts?: Object): boolean;
+ isLogicalExpression(opts?: Object): boolean;
+ isMemberExpression(opts?: Object): boolean;
+ isNewExpression(opts?: Object): boolean;
+ isProgram(opts?: Object): boolean;
+ isObjectExpression(opts?: Object): boolean;
+ isObjectMethod(opts?: Object): boolean;
+ isObjectProperty(opts?: Object): boolean;
+ isRestElement(opts?: Object): boolean;
+ isReturnStatement(opts?: Object): boolean;
+ isSequenceExpression(opts?: Object): boolean;
+ isSwitchCase(opts?: Object): boolean;
+ isSwitchStatement(opts?: Object): boolean;
+ isThisExpression(opts?: Object): boolean;
+ isThrowStatement(opts?: Object): boolean;
+ isTryStatement(opts?: Object): boolean;
+ isUnaryExpression(opts?: Object): boolean;
+ isUpdateExpression(opts?: Object): boolean;
+ isVariableDeclaration(opts?: Object): boolean;
+ isVariableDeclarator(opts?: Object): boolean;
+ isWhileStatement(opts?: Object): boolean;
+ isWithStatement(opts?: Object): boolean;
+ isAssignmentPattern(opts?: Object): boolean;
+ isArrayPattern(opts?: Object): boolean;
+ isArrowFunctionExpression(opts?: Object): boolean;
+ isClassBody(opts?: Object): boolean;
+ isClassDeclaration(opts?: Object): boolean;
+ isClassExpression(opts?: Object): boolean;
+ isExportAllDeclaration(opts?: Object): boolean;
+ isExportDefaultDeclaration(opts?: Object): boolean;
+ isExportNamedDeclaration(opts?: Object): boolean;
+ isExportSpecifier(opts?: Object): boolean;
+ isForOfStatement(opts?: Object): boolean;
+ isImportDeclaration(opts?: Object): boolean;
+ isImportDefaultSpecifier(opts?: Object): boolean;
+ isImportNamespaceSpecifier(opts?: Object): boolean;
+ isImportSpecifier(opts?: Object): boolean;
+ isMetaProperty(opts?: Object): boolean;
+ isClassMethod(opts?: Object): boolean;
+ isObjectPattern(opts?: Object): boolean;
+ isSpreadElement(opts?: Object): boolean;
+ isSuper(opts?: Object): boolean;
+ isTaggedTemplateExpression(opts?: Object): boolean;
+ isTemplateElement(opts?: Object): boolean;
+ isTemplateLiteral(opts?: Object): boolean;
+ isYieldExpression(opts?: Object): boolean;
+ isAnyTypeAnnotation(opts?: Object): boolean;
+ isArrayTypeAnnotation(opts?: Object): boolean;
+ isBooleanTypeAnnotation(opts?: Object): boolean;
+ isBooleanLiteralTypeAnnotation(opts?: Object): boolean;
+ isNullLiteralTypeAnnotation(opts?: Object): boolean;
+ isClassImplements(opts?: Object): boolean;
+ isClassProperty(opts?: Object): boolean;
+ isDeclareClass(opts?: Object): boolean;
+ isDeclareFunction(opts?: Object): boolean;
+ isDeclareInterface(opts?: Object): boolean;
+ isDeclareModule(opts?: Object): boolean;
+ isDeclareTypeAlias(opts?: Object): boolean;
+ isDeclareVariable(opts?: Object): boolean;
+ isExistentialTypeParam(opts?: Object): boolean;
+ isFunctionTypeAnnotation(opts?: Object): boolean;
+ isFunctionTypeParam(opts?: Object): boolean;
+ isGenericTypeAnnotation(opts?: Object): boolean;
+ isInterfaceExtends(opts?: Object): boolean;
+ isInterfaceDeclaration(opts?: Object): boolean;
+ isIntersectionTypeAnnotation(opts?: Object): boolean;
+ isMixedTypeAnnotation(opts?: Object): boolean;
+ isNullableTypeAnnotation(opts?: Object): boolean;
+ isNumericLiteralTypeAnnotation(opts?: Object): boolean;
+ isNumberTypeAnnotation(opts?: Object): boolean;
+ isStringLiteralTypeAnnotation(opts?: Object): boolean;
+ isStringTypeAnnotation(opts?: Object): boolean;
+ isThisTypeAnnotation(opts?: Object): boolean;
+ isTupleTypeAnnotation(opts?: Object): boolean;
+ isTypeofTypeAnnotation(opts?: Object): boolean;
+ isTypeAlias(opts?: Object): boolean;
+ isTypeAnnotation(opts?: Object): boolean;
+ isTypeCastExpression(opts?: Object): boolean;
+ isTypeParameterDeclaration(opts?: Object): boolean;
+ isTypeParameterInstantiation(opts?: Object): boolean;
+ isObjectTypeAnnotation(opts?: Object): boolean;
+ isObjectTypeCallProperty(opts?: Object): boolean;
+ isObjectTypeIndexer(opts?: Object): boolean;
+ isObjectTypeProperty(opts?: Object): boolean;
+ isQualifiedTypeIdentifier(opts?: Object): boolean;
+ isUnionTypeAnnotation(opts?: Object): boolean;
+ isVoidTypeAnnotation(opts?: Object): boolean;
+ isJSXAttribute(opts?: Object): boolean;
+ isJSXClosingElement(opts?: Object): boolean;
+ isJSXElement(opts?: Object): boolean;
+ isJSXEmptyExpression(opts?: Object): boolean;
+ isJSXExpressionContainer(opts?: Object): boolean;
+ isJSXIdentifier(opts?: Object): boolean;
+ isJSXMemberExpression(opts?: Object): boolean;
+ isJSXNamespacedName(opts?: Object): boolean;
+ isJSXOpeningElement(opts?: Object): boolean;
+ isJSXSpreadAttribute(opts?: Object): boolean;
+ isJSXText(opts?: Object): boolean;
+ isNoop(opts?: Object): boolean;
+ isParenthesizedExpression(opts?: Object): boolean;
+ isAwaitExpression(opts?: Object): boolean;
+ isBindExpression(opts?: Object): boolean;
+ isDecorator(opts?: Object): boolean;
+ isDoExpression(opts?: Object): boolean;
+ isExportDefaultSpecifier(opts?: Object): boolean;
+ isExportNamespaceSpecifier(opts?: Object): boolean;
+ isRestProperty(opts?: Object): boolean;
+ isSpreadProperty(opts?: Object): boolean;
+ isExpression(opts?: Object): boolean;
+ isBinary(opts?: Object): boolean;
+ isScopable(opts?: Object): boolean;
+ isBlockParent(opts?: Object): boolean;
+ isBlock(opts?: Object): boolean;
+ isStatement(opts?: Object): boolean;
+ isTerminatorless(opts?: Object): boolean;
+ isCompletionStatement(opts?: Object): boolean;
+ isConditional(opts?: Object): boolean;
+ isLoop(opts?: Object): boolean;
+ isWhile(opts?: Object): boolean;
+ isExpressionWrapper(opts?: Object): boolean;
+ isFor(opts?: Object): boolean;
+ isForXStatement(opts?: Object): boolean;
+ isFunction(opts?: Object): boolean;
+ isFunctionParent(opts?: Object): boolean;
+ isPureish(opts?: Object): boolean;
+ isDeclaration(opts?: Object): boolean;
+ isLVal(opts?: Object): boolean;
+ isLiteral(opts?: Object): boolean;
+ isImmutable(opts?: Object): boolean;
+ isUserWhitespacable(opts?: Object): boolean;
+ isMethod(opts?: Object): boolean;
+ isObjectMember(opts?: Object): boolean;
+ isProperty(opts?: Object): boolean;
+ isUnaryLike(opts?: Object): boolean;
+ isPattern(opts?: Object): boolean;
+ isClass(opts?: Object): boolean;
+ isModuleDeclaration(opts?: Object): boolean;
+ isExportDeclaration(opts?: Object): boolean;
+ isModuleSpecifier(opts?: Object): boolean;
+ isFlow(opts?: Object): boolean;
+ isFlowBaseAnnotation(opts?: Object): boolean;
+ isFlowDeclaration(opts?: Object): boolean;
+ isJSX(opts?: Object): boolean;
+ isNumberLiteral(opts?: Object): boolean;
+ isRegexLiteral(opts?: Object): boolean;
+ isReferencedIdentifier(opts?: Object): boolean;
+ isReferencedMemberExpression(opts?: Object): boolean;
+ isBindingIdentifier(opts?: Object): boolean;
+ isScope(opts?: Object): boolean;
+ isReferenced(opts?: Object): boolean;
+ isBlockScoped(opts?: Object): boolean;
+ isVar(opts?: Object): boolean;
+ isUser(opts?: Object): boolean;
+ isGenerated(opts?: Object): boolean;
+ isPure(opts?: Object): boolean;
+
+ // ------------------------- assertXXX -------------------------
+ assertArrayExpression(opts?: Object): void;
+ assertAssignmentExpression(opts?: Object): void;
+ assertBinaryExpression(opts?: Object): void;
+ assertDirective(opts?: Object): void;
+ assertDirectiveLiteral(opts?: Object): void;
+ assertBlockStatement(opts?: Object): void;
+ assertBreakStatement(opts?: Object): void;
+ assertCallExpression(opts?: Object): void;
+ assertCatchClause(opts?: Object): void;
+ assertConditionalExpression(opts?: Object): void;
+ assertContinueStatement(opts?: Object): void;
+ assertDebuggerStatement(opts?: Object): void;
+ assertDoWhileStatement(opts?: Object): void;
+ assertEmptyStatement(opts?: Object): void;
+ assertExpressionStatement(opts?: Object): void;
+ assertFile(opts?: Object): void;
+ assertForInStatement(opts?: Object): void;
+ assertForStatement(opts?: Object): void;
+ assertFunctionDeclaration(opts?: Object): void;
+ assertFunctionExpression(opts?: Object): void;
+ assertIdentifier(opts?: Object): void;
+ assertIfStatement(opts?: Object): void;
+ assertLabeledStatement(opts?: Object): void;
+ assertStringLiteral(opts?: Object): void;
+ assertNumericLiteral(opts?: Object): void;
+ assertNullLiteral(opts?: Object): void;
+ assertBooleanLiteral(opts?: Object): void;
+ assertRegExpLiteral(opts?: Object): void;
+ assertLogicalExpression(opts?: Object): void;
+ assertMemberExpression(opts?: Object): void;
+ assertNewExpression(opts?: Object): void;
+ assertProgram(opts?: Object): void;
+ assertObjectExpression(opts?: Object): void;
+ assertObjectMethod(opts?: Object): void;
+ assertObjectProperty(opts?: Object): void;
+ assertRestElement(opts?: Object): void;
+ assertReturnStatement(opts?: Object): void;
+ assertSequenceExpression(opts?: Object): void;
+ assertSwitchCase(opts?: Object): void;
+ assertSwitchStatement(opts?: Object): void;
+ assertThisExpression(opts?: Object): void;
+ assertThrowStatement(opts?: Object): void;
+ assertTryStatement(opts?: Object): void;
+ assertUnaryExpression(opts?: Object): void;
+ assertUpdateExpression(opts?: Object): void;
+ assertVariableDeclaration(opts?: Object): void;
+ assertVariableDeclarator(opts?: Object): void;
+ assertWhileStatement(opts?: Object): void;
+ assertWithStatement(opts?: Object): void;
+ assertAssignmentPattern(opts?: Object): void;
+ assertArrayPattern(opts?: Object): void;
+ assertArrowFunctionExpression(opts?: Object): void;
+ assertClassBody(opts?: Object): void;
+ assertClassDeclaration(opts?: Object): void;
+ assertClassExpression(opts?: Object): void;
+ assertExportAllDeclaration(opts?: Object): void;
+ assertExportDefaultDeclaration(opts?: Object): void;
+ assertExportNamedDeclaration(opts?: Object): void;
+ assertExportSpecifier(opts?: Object): void;
+ assertForOfStatement(opts?: Object): void;
+ assertImportDeclaration(opts?: Object): void;
+ assertImportDefaultSpecifier(opts?: Object): void;
+ assertImportNamespaceSpecifier(opts?: Object): void;
+ assertImportSpecifier(opts?: Object): void;
+ assertMetaProperty(opts?: Object): void;
+ assertClassMethod(opts?: Object): void;
+ assertObjectPattern(opts?: Object): void;
+ assertSpreadElement(opts?: Object): void;
+ assertSuper(opts?: Object): void;
+ assertTaggedTemplateExpression(opts?: Object): void;
+ assertTemplateElement(opts?: Object): void;
+ assertTemplateLiteral(opts?: Object): void;
+ assertYieldExpression(opts?: Object): void;
+ assertAnyTypeAnnotation(opts?: Object): void;
+ assertArrayTypeAnnotation(opts?: Object): void;
+ assertBooleanTypeAnnotation(opts?: Object): void;
+ assertBooleanLiteralTypeAnnotation(opts?: Object): void;
+ assertNullLiteralTypeAnnotation(opts?: Object): void;
+ assertClassImplements(opts?: Object): void;
+ assertClassProperty(opts?: Object): void;
+ assertDeclareClass(opts?: Object): void;
+ assertDeclareFunction(opts?: Object): void;
+ assertDeclareInterface(opts?: Object): void;
+ assertDeclareModule(opts?: Object): void;
+ assertDeclareTypeAlias(opts?: Object): void;
+ assertDeclareVariable(opts?: Object): void;
+ assertExistentialTypeParam(opts?: Object): void;
+ assertFunctionTypeAnnotation(opts?: Object): void;
+ assertFunctionTypeParam(opts?: Object): void;
+ assertGenericTypeAnnotation(opts?: Object): void;
+ assertInterfaceExtends(opts?: Object): void;
+ assertInterfaceDeclaration(opts?: Object): void;
+ assertIntersectionTypeAnnotation(opts?: Object): void;
+ assertMixedTypeAnnotation(opts?: Object): void;
+ assertNullableTypeAnnotation(opts?: Object): void;
+ assertNumericLiteralTypeAnnotation(opts?: Object): void;
+ assertNumberTypeAnnotation(opts?: Object): void;
+ assertStringLiteralTypeAnnotation(opts?: Object): void;
+ assertStringTypeAnnotation(opts?: Object): void;
+ assertThisTypeAnnotation(opts?: Object): void;
+ assertTupleTypeAnnotation(opts?: Object): void;
+ assertTypeofTypeAnnotation(opts?: Object): void;
+ assertTypeAlias(opts?: Object): void;
+ assertTypeAnnotation(opts?: Object): void;
+ assertTypeCastExpression(opts?: Object): void;
+ assertTypeParameterDeclaration(opts?: Object): void;
+ assertTypeParameterInstantiation(opts?: Object): void;
+ assertObjectTypeAnnotation(opts?: Object): void;
+ assertObjectTypeCallProperty(opts?: Object): void;
+ assertObjectTypeIndexer(opts?: Object): void;
+ assertObjectTypeProperty(opts?: Object): void;
+ assertQualifiedTypeIdentifier(opts?: Object): void;
+ assertUnionTypeAnnotation(opts?: Object): void;
+ assertVoidTypeAnnotation(opts?: Object): void;
+ assertJSXAttribute(opts?: Object): void;
+ assertJSXClosingElement(opts?: Object): void;
+ assertJSXElement(opts?: Object): void;
+ assertJSXEmptyExpression(opts?: Object): void;
+ assertJSXExpressionContainer(opts?: Object): void;
+ assertJSXIdentifier(opts?: Object): void;
+ assertJSXMemberExpression(opts?: Object): void;
+ assertJSXNamespacedName(opts?: Object): void;
+ assertJSXOpeningElement(opts?: Object): void;
+ assertJSXSpreadAttribute(opts?: Object): void;
+ assertJSXText(opts?: Object): void;
+ assertNoop(opts?: Object): void;
+ assertParenthesizedExpression(opts?: Object): void;
+ assertAwaitExpression(opts?: Object): void;
+ assertBindExpression(opts?: Object): void;
+ assertDecorator(opts?: Object): void;
+ assertDoExpression(opts?: Object): void;
+ assertExportDefaultSpecifier(opts?: Object): void;
+ assertExportNamespaceSpecifier(opts?: Object): void;
+ assertRestProperty(opts?: Object): void;
+ assertSpreadProperty(opts?: Object): void;
+ assertExpression(opts?: Object): void;
+ assertBinary(opts?: Object): void;
+ assertScopable(opts?: Object): void;
+ assertBlockParent(opts?: Object): void;
+ assertBlock(opts?: Object): void;
+ assertStatement(opts?: Object): void;
+ assertTerminatorless(opts?: Object): void;
+ assertCompletionStatement(opts?: Object): void;
+ assertConditional(opts?: Object): void;
+ assertLoop(opts?: Object): void;
+ assertWhile(opts?: Object): void;
+ assertExpressionWrapper(opts?: Object): void;
+ assertFor(opts?: Object): void;
+ assertForXStatement(opts?: Object): void;
+ assertFunction(opts?: Object): void;
+ assertFunctionParent(opts?: Object): void;
+ assertPureish(opts?: Object): void;
+ assertDeclaration(opts?: Object): void;
+ assertLVal(opts?: Object): void;
+ assertLiteral(opts?: Object): void;
+ assertImmutable(opts?: Object): void;
+ assertUserWhitespacable(opts?: Object): void;
+ assertMethod(opts?: Object): void;
+ assertObjectMember(opts?: Object): void;
+ assertProperty(opts?: Object): void;
+ assertUnaryLike(opts?: Object): void;
+ assertPattern(opts?: Object): void;
+ assertClass(opts?: Object): void;
+ assertModuleDeclaration(opts?: Object): void;
+ assertExportDeclaration(opts?: Object): void;
+ assertModuleSpecifier(opts?: Object): void;
+ assertFlow(opts?: Object): void;
+ assertFlowBaseAnnotation(opts?: Object): void;
+ assertFlowDeclaration(opts?: Object): void;
+ assertJSX(opts?: Object): void;
+ assertNumberLiteral(opts?: Object): void;
+ assertRegexLiteral(opts?: Object): void;
+ }
+
+ export class Hub {
+ constructor(file: any, options: any);
+ file: any;
+ options: any;
+ }
+
+ interface TraversalContext {
+ parentPath: NodePath;
+ scope: Scope;
+ state: any;
+ opts: any;
+ }
+}
diff --git a/babel-traverse/tsconfig.json b/babel-traverse/tsconfig.json
new file mode 100644
index 0000000000..ac08134cd7
--- /dev/null
+++ b/babel-traverse/tsconfig.json
@@ -0,0 +1,9 @@
+{
+ "compilerOptions": {
+ "module": "commonjs",
+ "target": "es2015",
+ "noImplicitAny": true,
+ "strictNullChecks": true,
+ "baseUrl": "../"
+ }
+}
\ No newline at end of file
diff --git a/babel-types/babel-types-tests.ts b/babel-types/babel-types-tests.ts
new file mode 100644
index 0000000000..2a8a25a961
--- /dev/null
+++ b/babel-types/babel-types-tests.ts
@@ -0,0 +1,26 @@
+///
+///
+
+
+// Examples from https://github.com/thejameskyle/babel-handbook/blob/master/translations/en/plugin-handbook.md#babel-types
+import traverse from "babel-traverse";
+import * as t from "babel-types";
+
+let ast: t.Node;
+
+traverse(ast, {
+ enter(path) {
+ let node = path.node;
+ if (t.isIdentifier(node, { name: "n" })) {
+ node.name = "x";
+ }
+ }
+});
+
+if (t.isBinaryExpression(ast)) {
+ ast.left;
+ ast.right;
+ ast.operator;
+}
+t.assertBinaryExpression(ast);
+t.assertBinaryExpression(ast, { operator: "*" });
diff --git a/babel-types/babel-types.d.ts b/babel-types/babel-types.d.ts
new file mode 100644
index 0000000000..d10302370a
--- /dev/null
+++ b/babel-types/babel-types.d.ts
@@ -0,0 +1,1403 @@
+// Type definitions for babel-types v6.7
+// Project: https://github.com/babel/babel/tree/master/packages/babel-types
+// Definitions by: Troy Gerwien
+// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
+
+declare module "babel-types" {
+
+ export interface Comment {
+ value: string;
+ start: number;
+ end: number;
+ loc: SourceLocation;
+ }
+
+ export interface CommentBlock extends Comment {
+ type: "CommentBlock";
+ }
+
+ export interface CommentLine extends Comment {
+ type: "CommentLine";
+ }
+
+ export interface SourceLocation {
+ start: {
+ line: number;
+ column: number;
+ };
+
+ end: {
+ line: number;
+ column: number;
+ };
+ }
+
+ export interface Node {
+ type: string;
+ leadingComments?: Array;
+ innerComments?: Array;
+ trailingComments?: Array;
+ start: number;
+ end: number;
+ loc: SourceLocation;
+ }
+
+ export interface ArrayExpression extends Node {
+ type: "ArrayExpression";
+ elements: Array;
+ }
+
+ export interface AssignmentExpression extends Node {
+ type: "AssignmentExpression";
+ operator: "=" | "+=" | "-=" | "*=" | "/=" | "%=" | "<<=" | ">>=" | ">>>=" | "|=" | "^=" | "&=";
+ left: LVal;
+ right: Expression;
+ }
+
+ export interface BinaryExpression extends Node {
+ type: "BinaryExpression";
+ operator: "+" | "-" | "/" | "%" | "*" | "**" | "&" | "|" | ">>" | ">>>" | "<<" | "^" | "==" | "===" | "!=" | "!==" | "in" | "instanceof" | ">" | "<" | ">=" | "<=";
+ left: Expression;
+ right: Expression;
+ }
+
+ export interface Directive extends Node {
+ type: "Directive";
+ value: DirectiveLiteral;
+ }
+
+ export interface DirectiveLiteral extends Node {
+ type: "DirectiveLiteral";
+ value: string;
+ }
+
+ export interface BlockStatement extends Node {
+ type: "BlockStatement";
+ directives?: Directive[];
+ body: Statement[];
+ }
+
+ export interface BreakStatement extends Node {
+ type: "BreakStatement";
+ label: Identifier;
+ }
+
+ export interface CallExpression extends Node {
+ type: "CallExpression";
+ callee: Expression | Super;
+ arguments: Array;
+ }
+
+ export interface CatchClause extends Node {
+ type: "CatchClause";
+ param: Pattern;
+ body: BlockStatement;
+ }
+
+ export interface ConditionalExpression extends Node {
+ type: "ConditionalExpression";
+ test: Expression;
+ consequent: Expression;
+ alternate: Expression;
+ }
+
+ export interface ContinueStatement extends Node {
+ type: "ContinueStatement";
+ label: Identifier;
+ }
+
+ export interface DebuggerStatement extends Node {
+ type: "DebuggerStatement";
+ }
+
+ export interface DoWhileStatement extends Node {
+ type: "DoWhileStatement";
+ test: Expression;
+ body: Statement;
+ }
+
+ export interface EmptyStatement extends Node {
+ type: "EmptyStatement";
+ }
+
+ export interface ExpressionStatement extends Node {
+ type: "ExpressionStatement";
+ expression: Expression;
+ }
+
+ export interface File extends Node {
+ type: "File";
+ program: Program;
+ comments: Comment[];
+ tokens: any[];
+ }
+
+ export interface ForInStatement extends Node {
+ type: "ForInStatement";
+ left: VariableDeclaration | LVal;
+ right: Expression;
+ body: Statement;
+ }
+
+ export interface ForStatement extends Node {
+ type: "ForStatement";
+ init: VariableDeclaration | Expression;
+ test: Expression;
+ update: Expression;
+ body: Statement;
+ }
+
+ export interface FunctionDeclaration extends Node {
+ type: "FunctionDeclaration";
+ id: Identifier;
+ params: Pattern[];
+ body: BlockStatement;
+ generator: boolean;
+ async: boolean;
+ returnType?: TypeAnnotation;
+ typeParameters?: TypeParameterDeclaration;
+ }
+
+ export interface FunctionExpression extends Node {
+ type: "FunctionExpression";
+ id: Identifier;
+ params: Pattern[];
+ body: BlockStatement;
+ generator: boolean;
+ async: boolean;
+ returnType?: TypeAnnotation;
+ typeParameters?: TypeParameterDeclaration;
+ }
+
+ export interface Identifier extends Node {
+ type: "Identifier";
+ name: string;
+ typeAnnotation?: TypeAnnotation;
+ }
+
+ export interface IfStatement extends Node {
+ type: "IfStatement";
+ test: Expression;
+ consequent: Statement;
+ alternate: Statement;
+ }
+
+ export interface LabeledStatement extends Node {
+ type: "LabeledStatement";
+ label: Identifier;
+ body: Statement;
+ }
+
+ export interface StringLiteral extends Node {
+ type: "StringLiteral";
+ value: string;
+ }
+
+ export interface NumericLiteral extends Node {
+ type: "NumericLiteral";
+ value: number;
+ }
+
+ export interface NullLiteral extends Node {
+ type: "NullLiteral";
+ }
+
+ export interface BooleanLiteral extends Node {
+ type: "BooleanLiteral";
+ value: boolean;
+ }
+
+ export interface RegExpLiteral extends Node {
+ type: "RegExpLiteral";
+ pattern: string;
+ flags?: string;
+ }
+
+ export interface LogicalExpression extends Node {
+ type: "LogicalExpression";
+ operator: "||" | "&&";
+ left: Expression;
+ right: Expression;
+ }
+
+ export interface MemberExpression extends Node {
+ type: "MemberExpression";
+ object: Expression | Super;
+ property: Expression;
+ computed: boolean;
+ }
+
+ export interface NewExpression extends Node {
+ type: "NewExpression";
+ callee: Expression | Super;
+ arguments: Array;
+ }
+
+ export interface Program extends Node {
+ type: "Program";
+ sourceType: "script" | "module";
+ directives?: Directive[];
+ body: Array;
+ }
+
+ export interface ObjectExpression extends Node {
+ type: "ObjectExpression";
+ properties: Array;
+ }
+
+ export interface ObjectMethod extends Node {
+ type: "ObjectMethod";
+ key: Expression;
+ kind: "get" | "set" | "method";
+ shorthand: boolean;
+ computed: boolean;
+ value: Expression;
+ decorators?: Decorator[];
+ id: Identifier;
+ params: Pattern[];
+ body: BlockStatement;
+ generator: boolean;
+ async: boolean;
+ returnType?: TypeAnnotation;
+ typeParameters?: TypeParameterDeclaration;
+ }
+
+ export interface ObjectProperty extends Node {
+ type: "ObjectProperty";
+ key: Expression;
+ computed: boolean;
+ value: Expression;
+ decorators?: Decorator[];
+ shorthand: boolean;
+ }
+
+ export interface RestElement extends Node {
+ type: "RestElement";
+ argument: LVal;
+ typeAnnotation?: TypeAnnotation;
+ }
+
+ export interface ReturnStatement extends Node {
+ type: "ReturnStatement";
+ argument: Expression;
+ }
+
+ export interface SequenceExpression extends Node {
+ type: "SequenceExpression";
+ expressions: Expression[];
+ }
+
+ export interface SwitchCase extends Node {
+ type: "SwitchCase";
+ test: Expression;
+ consequent: Statement[];
+ }
+
+ export interface SwitchStatement extends Node {
+ type: "SwitchStatement";
+ discriminant: Expression;
+ cases: SwitchCase[];
+ }
+
+ export interface ThisExpression extends Node {
+ type: "ThisExpression";
+ }
+
+ export interface ThrowStatement extends Node {
+ type: "ThrowStatement";
+ argument: Expression;
+ }
+
+ export interface TryStatement extends Node {
+ type: "TryStatement";
+ block: BlockStatement;
+ handler: CatchClause;
+ finalizer: BlockStatement;
+ }
+
+ export interface UnaryExpression extends Node {
+ type: "UnaryExpression";
+ operator: "-" | "+" | "!" | "~" | "typeof" | "void" | "delete";
+ prefix: boolean;
+ argument: Expression;
+ }
+
+ export interface UpdateExpression extends Node {
+ type: "UpdateExpression";
+ operator: "++" | "--";
+ prefix: boolean;
+ argument: Expression;
+ }
+
+ export interface VariableDeclaration extends Node {
+ type: "VariableDeclaration";
+ declarations: VariableDeclarator[];
+ kind: "var" | "let" | "const";
+ }
+
+ export interface VariableDeclarator extends Node {
+ type: "VariableDeclarator";
+ id: LVal;
+ init: Expression;
+ }
+
+ export interface WhileStatement extends Node {
+ type: "WhileStatement";
+ test: Expression;
+ body: Statement;
+ }
+
+ export interface WithStatement extends Node {
+ type: "WithStatement";
+ object: Expression;
+ body: BlockStatement | Statement;
+ }
+
+ export interface AssignmentPattern extends Node {
+ type: "AssignmentPattern";
+ left: Pattern;
+ right: Expression;
+ }
+
+ export interface ArrayPattern extends Node {
+ type: "ArrayPattern";
+ elements: Array;
+ typeAnnotation?: TypeAnnotation;
+ }
+
+ export interface ArrowFunctionExpression extends Node {
+ type: "ArrowFunctionExpression";
+ id: Identifier;
+ params: Pattern[];
+ body: BlockStatement | Expression;
+ generator: boolean;
+ async: boolean;
+ expression: boolean;
+ returnType?: TypeAnnotation;
+ typeParameters?: TypeParameterDeclaration;
+ }
+
+ export interface ClassBody extends Node {
+ type: "ClassBody";
+ body: Array;
+ }
+
+ export interface ClassDeclaration extends Node {
+ type: "ClassDeclaration";
+ id: Identifier;
+ superClass: Expression;
+ body: ClassBody;
+ decorators?: Decorator[];
+ implements?: ClassImplements[];
+ mixins?: any[];
+ typeParameters?: TypeParameterDeclaration;
+ superTypeParameters?: TypeParameterInstantiation;
+ }
+
+ export interface ClassExpression extends Node {
+ type: "ClassExpression";
+ id: Identifier;
+ superClass: Expression;
+ body: ClassBody;
+ decorators?: Decorator[];
+ implements?: ClassImplements[];
+ mixins?: any[];
+ typeParameters?: TypeParameterDeclaration;
+ superTypeParameters?: TypeParameterInstantiation;
+ }
+
+ export interface ExportAllDeclaration extends Node {
+ type: "ExportAllDeclaration";
+ source: StringLiteral;
+ }
+
+ export interface ExportDefaultDeclaration extends Node {
+ type: "ExportDefaultDeclaration";
+ declaration: Declaration | Expression;
+ }
+
+ export interface ExportNamedDeclaration extends Node {
+ type: "ExportNamedDeclaration";
+ declaration: Declaration;
+ specifiers: ExportSpecifier[];
+ source: StringLiteral;
+ }
+
+ export interface ExportSpecifier extends Node {
+ type: "ExportSpecifier";
+ local: Identifier;
+ imported: Identifier;
+ exported: Identifier;
+ }
+
+ export interface ForOfStatement extends Node {
+ type: "ForOfStatement";
+ left: VariableDeclaration | LVal;
+ right: Expression;
+ body: Statement;
+ }
+
+ export interface ImportDeclaration extends Node {
+ type: "ImportDeclaration";
+ specifiers: Array;
+ source: StringLiteral;
+ }
+
+ export interface ImportDefaultSpecifier extends Node {
+ type: "ImportDefaultSpecifier";
+ local: Identifier;
+ }
+
+ export interface ImportNamespaceSpecifier extends Node {
+ type: "ImportNamespaceSpecifier";
+ local: Identifier;
+ }
+
+ export interface ImportSpecifier extends Node {
+ type: "ImportSpecifier";
+ local: Identifier;
+ imported: Identifier;
+ }
+
+ export interface MetaProperty extends Node {
+ type: "MetaProperty";
+ meta: Identifier;
+ property: Identifier;
+ }
+
+ export interface ClassMethod extends Node {
+ type: "ClassMethod";
+ key: Expression;
+ value?: FunctionExpression;
+ kind: "constructor" | "method" | "get" | "set";
+ computed: boolean;
+ static: boolean;
+ decorators?: Decorator[];
+ id: Identifier;
+ params: Pattern[];
+ body: BlockStatement;
+ generator: boolean;
+ async: boolean;
+ expression: boolean;
+ returnType?: TypeAnnotation;
+ typeParameters?: TypeParameterDeclaration;
+ }
+
+ // See: https://github.com/babel/babel/blob/master/doc/ast/spec.md#objectpattern
+ export interface AssignmentProperty extends Node {
+ type: "ObjectProperty";
+ key: Expression;
+ computed: boolean;
+ value: Pattern;
+ decorators?: Decorator[];
+ shorthand: boolean;
+ }
+
+ export interface ObjectPattern extends Node {
+ type: "ObjectPattern";
+ properties: Array