Skip to content

Commit 990da0b

Browse files
committed
Fix execution order of file generation
1 parent b4ff404 commit 990da0b

File tree

5 files changed

+11
-10
lines changed

5 files changed

+11
-10
lines changed

example/package-lock.json

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

example/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
"author": "",
1212
"license": "ISC",
1313
"devDependencies": {
14-
"typedoc-plugin-typescript-declaration": "^0.2.1"
14+
"typedoc-plugin-typescript-declaration": "^0.2.2"
1515
},
1616
"dependencies": {}
1717
}

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "typedoc-plugin-typescript-declaration",
3-
"version": "0.2.1",
3+
"version": "0.2.2",
44
"description": "Typedoc plugin to render to typescript declaration file",
55
"main": "dist/index.js",
66
"bin": {

src/cli-application.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,10 +62,6 @@ export class CliApplication extends Application {
6262
let hasOutput = false;
6363

6464
if (project) {
65-
if (declarationFile) {
66-
TypeScriptDeclarationPlugin.generateTypeDeclarations(project, sorOption, declarationFile);
67-
hasOutput = true;
68-
}
6965
if (out && !declarationOnly) {
7066
this.generateDocs(project, out);
7167
hasOutput = true;
@@ -75,6 +71,11 @@ export class CliApplication extends Application {
7571
hasOutput = true;
7672
}
7773

74+
if (declarationFile) {
75+
TypeScriptDeclarationPlugin.generateTypeDeclarations(project, sorOption, declarationFile);
76+
hasOutput = true;
77+
}
78+
7879
if (!hasOutput) {
7980
console.log('Nothing generated, use --declarationOnly, --out, or --json options');
8081
}

0 commit comments

Comments
 (0)