Skip to content

Commit

Permalink
Set up TypeScript compilation.
Browse files Browse the repository at this point in the history
  • Loading branch information
benjamn committed Jan 22, 2019
1 parent ae3136e commit 021243b
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,6 @@ jspm_packages

# Optional REPL history
.node_repl_history

# Ignore generated TypeScript files.
lib
1 change: 1 addition & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
/node_modules
/test
/src
6 changes: 6 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 5 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,16 @@
"url": "https://github.com/benjamn/optimism/issues"
},
"scripts": {
"test": "mocha --reporter spec --full-trace test/tests.js"
"build": "tsc",
"mocha": "mocha --reporter spec --full-trace test/tests.js",
"test": "npm run build && npm run mocha"
},
"dependencies": {
"immutable-tuple": "^0.4.10"
},
"devDependencies": {
"fibers": "^3.0.0",
"mocha": "^5.0.0"
"mocha": "^5.0.0",
"typescript": "^3.2.4"
}
}
13 changes: 13 additions & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"compilerOptions": {
"target": "es5",
"module": "commonjs",
"rootDir": "./src",
"outDir": "./lib",
"declaration": true,
"lib": ["es2015"],
"strict": true,
"noImplicitAny": true,
"esModuleInterop": true
}
}

0 comments on commit 021243b

Please sign in to comment.