UNPKG
typescript-formatter
Version:
latest (7.2.2)
next (6.0.0)
7.2.2
7.2.1
7.2.0
7.1.0
7.0.1
7.0.0
6.1.0
6.0.0
5.2.0
5.1.3
5.1.2
5.1.1
5.1.0
5.0.1
5.0.0
4.2.2
4.2.1
4.2.0
4.1.2
4.1.1
4.1.0
4.0.1
4.0.0
3.1.0
3.0.1
3.0.0
2.3.0
2.2.1
2.2.0
2.1.0
2.0.0
1.2.0
1.1.0
1.0.0
0.4.3
0.4.2
0.4.1
0.4.0
0.3.2
0.3.1
0.3.0
0.2.2
0.2.1
0.2.0
0.1.4
0.1.3
0.1.2
0.1.1
0.1.0
0.0.5
0.0.4
0.0.3
0.0.2
0.0.1
Formatter of TypeScript code
github.com/vvakame/typescript-formatter
vvakame/typescript-formatter
typescript-formatter
/
example
/
index.ts
16 lines
(14 loc)
•
265 B
text/typescript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import *
as
tsfmt
from
"typescript-formatter"
; tsfmt .
processFiles
([
"./index.ts"
], {
dryRun
:
true
,
replace
:
false
,
verify
:
false
,
tsconfig
:
true
,
tslint
:
true
,
editorconfig
:
true
,
tsfmt
:
true
}) .
then
(result =>{ console.
log
(result[
"./index.ts"
].dest); });