diff --git a/shared/generate_declarations.sh b/shared/generate_declarations.sh index 99d87c07..9817ea95 100644 --- a/shared/generate_declarations.sh +++ b/shared/generate_declarations.sh @@ -24,11 +24,5 @@ function generate_declaration() { #Generate the loader definitions first app_declaration="../declarations/shared-app/" -loader_declaration_app="../declarations/loader/" -# loader_declaration_certaccept="declarations/exports_loader_certaccept.d.ts" - generate_declaration dtsconfig_app.json ${app_declaration} -generate_declaration dtsconfig_loader_app.json ${loader_declaration_app} -# generate_declaration dtsconfig_loader_certaccept.json ${loader_declaration_certaccept} - exit 0 \ No newline at end of file diff --git a/shared/tsconfig/dtsconfig_loader_app.json b/shared/tsconfig/dtsconfig_loader_app.json deleted file mode 100644 index 0c46a347..00000000 --- a/shared/tsconfig/dtsconfig_loader_app.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "source_files": [ - "../loader/loader.ts", - "../loader/app.ts" - ], - "target_file": "../declarations/exports_loader_app.d.ts" -} \ No newline at end of file diff --git a/shared/tsconfig/dtsconfig_loader_certaccept.json b/shared/tsconfig/dtsconfig_loader_certaccept.json deleted file mode 100644 index a52a4d85..00000000 --- a/shared/tsconfig/dtsconfig_loader_certaccept.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "source_files": [ - "../loader/loader.ts", - "../loader/certaccept.ts" - ], - "target_file": "../declarations/exports_loader_certaccept.d.ts" -} \ No newline at end of file diff --git a/shared/tsconfig/tsconfig_certaccept.json b/shared/tsconfig/tsconfig_certaccept.json deleted file mode 100644 index d4e1b999..00000000 --- a/shared/tsconfig/tsconfig_certaccept.json +++ /dev/null @@ -1,16 +0,0 @@ -/* general shared project config */ -{ - "compilerOptions": { - "target": "es6", - "module": "commonjs", - "sourceMap": true, - "experimentalDecorators": true, - "plugins": [ ] - }, - "include": [ - "../types", - "../declarations/exports_loader_certaccept.d.ts", - "../popup/certaccept/js/**/*.ts", - "../js/BrowserIPC.ts" - ] -} \ No newline at end of file diff --git a/shared/tsconfig/tsconfig_packed_certaccept.json b/shared/tsconfig/tsconfig_packed_certaccept.json deleted file mode 100644 index bcc0b2f1..00000000 --- a/shared/tsconfig/tsconfig_packed_certaccept.json +++ /dev/null @@ -1,18 +0,0 @@ -/* general shared project config */ -{ - "compilerOptions": { - "target": "es6", - "module": "none", - "outFile": "../generated/certaccept.js", - "plugins": [ ] - }, - "include": [ - "../types", - "../declarations/exports_loader_certaccept.d.ts", - "../popup/certaccept/js/**/*.ts", - "../js/BrowserIPC.ts", - "../js/settings.ts", - "../js/proto.ts", - "../js/log.ts" - ] -} \ No newline at end of file diff --git a/shared/tsconfig/tsconfig_packed_loader_app.json b/shared/tsconfig/tsconfig_packed_loader_app.json deleted file mode 100644 index 186834d2..00000000 --- a/shared/tsconfig/tsconfig_packed_loader_app.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "compilerOptions": { - "target": "es6", - "module": "none", - "sourceMap": true, - "outFile": "../generated/loader_app.js" - }, - "include": [ - "../types", - "../declarations/imports_*.d.ts", - "../declarations/exports_app.d.ts", /* lets include them because we require stuff like the log */ - "../loader/loader.ts", - "../loader/app.ts", - "../backend" - ] -} \ No newline at end of file diff --git a/shared/tsconfig/tsconfig_packed_loader_certaccept.json b/shared/tsconfig/tsconfig_packed_loader_certaccept.json deleted file mode 100644 index 3485d843..00000000 --- a/shared/tsconfig/tsconfig_packed_loader_certaccept.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "compilerOptions": { - "target": "es6", - "module": "none", - "sourceMap": true, - "outFile": "../generated/loader_certaccept.js" - }, - "include": [ - "../types", - "../loader/loader.ts", - "../loader/certaccept.ts", - /* - Lets include them because we require stuff like the log. - More sense would it to make an extra d.ts file for that, but who cares - */ - "../declarations/exports_app.d.ts" - ] -} \ No newline at end of file diff --git a/tools/dtsgen/declare_fixup.ts b/tools/dtsgen/declare_fixup.ts index cc9b0f12..b39eea28 100644 --- a/tools/dtsgen/declare_fixup.ts +++ b/tools/dtsgen/declare_fixup.ts @@ -12,6 +12,4 @@ export function fix_declare_global(nodes: ts.Node[]) : ts.Node[] { if(has_export) return nodes; return []; -} - -SyntaxKind.PlusEqualsToken \ No newline at end of file +} \ No newline at end of file diff --git a/tools/dtsgen/import_organizer.ts b/tools/dtsgen/import_organizer.ts index e791195d..faa5e1b4 100644 --- a/tools/dtsgen/import_organizer.ts +++ b/tools/dtsgen/import_organizer.ts @@ -255,6 +255,11 @@ function analyze_type_node(node: ts.TypeNode | ts.LeftHandSideExpression, data: analyze_type_node(pae.expression, data); break; + case SyntaxKind.ConstructorType: + let ct = node as ts.ConstructorTypeNode; + analyze_type_node(ct.type, data); + break; + default: throw "Unknown type " + SyntaxKind[node.kind] + ". Extend me :)"; }