Skip to content

Commit 98914b1

Browse files
chore(typescript): Check noImplicitAny compliance in travis script
1 parent be50e6d commit 98914b1

File tree

3 files changed

+9
-3
lines changed

3 files changed

+9
-3
lines changed

.travis.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,7 @@ script:
3333
popd && \
3434
npm install ./ui-router-core ;
3535
fi
36-
- npm run build
37-
- npm run test
36+
- npm run travis
3837

3938
sudo: false
4039

package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,11 @@
77
"compile": "npm run clean && ngc",
88
"bundle": "rollup -c && rollup -c --environment MINIFY",
99
"build": "npm run compile && npm run bundle",
10+
"travis": "npm run build && npm run noimplicitany && npm run test",
1011
"test": "karma start",
12+
"noimplicitany": "tsc --noEmit --noImplicitAny --moduleResolution node --target es6 test/noimplicitany.ts",
1113
"debug": "karma start --singleRun=false --autoWatch=true --autoWatchInterval=1 --browsers=Chrome",
12-
"package": "npm run bundle",
14+
"package": "npm run build",
1315
"docs": "typedoc --tsconfig tsconfig.typedoc.json --readme README.md --name 'ui-router-ng2' --theme node_modules/ui-router-typedoc-themes/bin/default --out _doc --internal-aliases internal,coreapi,ng2api --external-aliases internalapi,external --navigation-label-globals ui-router-ng2",
1416
"prepublish": "npm run build"
1517
},

test/noimplicitany.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
// This file should be compiled using --noImplicitAny to ensure the .d.ts files are noImplicitAny compliant.
2+
// tsc --noEmit --noImplicitAny --moduleResolution node --target es6 test/noimplicitany.ts
3+
4+
import * as router from "../lib/index";
5+
console.log(router);

0 commit comments

Comments
 (0)