Skip to content

Commit

Permalink
fix: support typescript in dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
czy88840616 committed Aug 14, 2018
1 parent b8b4c7d commit b532a90
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/midway/cluster/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ exports.formatOptions = (options) => {
options.typescript = true;
} else {
const pkg = require(path.join(options.baseDir, 'package.json'));
if(pkg['dependencies'] && pkg['dependencies']['typescript']) {
options.typescript = true;
}
if(pkg['devDependencies'] && pkg['devDependencies']['typescript']) {
options.typescript = true;
}
Expand Down

0 comments on commit b532a90

Please sign in to comment.