Skip to content

Commit

Permalink
Fix TypeScript verification
Browse files Browse the repository at this point in the history
  • Loading branch information
mrmckeb committed Sep 23, 2019
1 parent 565fc1a commit 3964653
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 2 additions & 3 deletions packages/react-scripts/scripts/init.js
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,6 @@ module.exports = function(
if ((!isReactInstalled(appPackage) || templateName) && args.length > 1) {
console.log();
console.log(`Installing template dependencies using ${command}...`);
console.log();

const proc = spawn.sync(command, args, { stdio: 'inherit' });
if (proc.status !== 0) {
Expand All @@ -215,12 +214,12 @@ module.exports = function(
}
}

if (appPackage.dependencies['typescript'] != null) {
if (args.find(arg => arg.includes('typescript'))) {
console.log();
verifyTypeScriptSetup();
}

// Remove template
console.log();
console.log(`Removing template package using ${command}...`);
console.log();

Expand Down
2 changes: 2 additions & 0 deletions tasks/e2e-installs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,8 @@ exists tsconfig.json
exists src/react-app-env.d.ts
checkTypeScriptDependencies

node node_modules/react-scripts/scripts/utils/verifyTypeScriptSetup.js

# Check that the TypeScript template passes smoke tests, build, and normal tests
yarn start --smoke-test
yarn build
Expand Down

0 comments on commit 3964653

Please sign in to comment.