Skip to content

Commit 52b36f3

Browse files
committed
Fix TypeScript verification
1 parent 8c38701 commit 52b36f3

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

packages/react-scripts/scripts/init.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,6 @@ module.exports = function(
224224
if ((!isReactInstalled(appPackage) || templateName) && args.length > 1) {
225225
console.log();
226226
console.log(`Installing template dependencies using ${command}...`);
227-
console.log();
228227

229228
const proc = spawn.sync(command, args, { stdio: 'inherit' });
230229
if (proc.status !== 0) {
@@ -233,12 +232,12 @@ module.exports = function(
233232
}
234233
}
235234

236-
if (appPackage.dependencies['typescript'] != null) {
235+
if (args.find(arg => arg.includes('typescript'))) {
236+
console.log();
237237
verifyTypeScriptSetup();
238238
}
239239

240240
// Remove template
241-
console.log();
242241
console.log(`Removing template package using ${command}...`);
243242
console.log();
244243

tasks/e2e-installs.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,6 +162,8 @@ exists tsconfig.json
162162
exists src/react-app-env.d.ts
163163
checkTypeScriptDependencies
164164

165+
node node_modules/react-scripts/scripts/utils/verifyTypeScriptSetup.js
166+
165167
# Check that the TypeScript template passes smoke tests, build, and normal tests
166168
yarn start --smoke-test
167169
yarn build

0 commit comments

Comments
 (0)