Skip to content

Commit 0ce0aef

Browse files
Allow type truncation (#32)
1 parent e94242c commit 0ce0aef

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@joernio/astgen",
3-
"version": "3.25.0",
3+
"version": "3.26.0",
44
"description": "Generate JS/TS AST in json format with Babel",
55
"exports": "./index.js",
66
"keywords": [

src/TscUtils.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,15 @@ export function tscForFiles(srcFiles: string[]): TscResult {
1616

1717
function safeTypeToString(node: tsc.Type): string {
1818
try {
19-
return typeChecker.typeToString(node, undefined, tsc.TypeFormatFlags.NoTruncation | tsc.TypeFormatFlags.InTypeAlias);
19+
return typeChecker.typeToString(node, undefined, tsc.TypeFormatFlags.InTypeAlias);
2020
} catch (err) {
2121
return "any";
2222
}
2323
}
2424

2525
function safeTypeWithContextToString(node: tsc.Type, context: tsc.Node): string {
2626
try {
27-
return typeChecker.typeToString(node, context, tsc.TypeFormatFlags.NoTruncation | tsc.TypeFormatFlags.InTypeAlias);
27+
return typeChecker.typeToString(node, context, tsc.TypeFormatFlags.InTypeAlias);
2828
} catch (err) {
2929
return "any";
3030
}

0 commit comments

Comments
 (0)