1010// Makes the script crash on unhandled rejections instead of silently
1111// ignoring them. In the future, promise rejections that are not handled will
1212// terminate the Node.js process with a non-zero exit code.
13- process . on ( 'unhandledRejection' , err => {
13+ process . on ( 'unhandledRejection' , ( err ) => {
1414 throw err ;
1515} ) ;
1616
@@ -84,7 +84,7 @@ function tryGitCommit(appPath) {
8484 }
8585}
8686
87- module . exports = function (
87+ module . exports = function (
8888 appPath ,
8989 appName ,
9090 verbose ,
@@ -163,12 +163,14 @@ module.exports = function(
163163
164164 // Keys from templatePackage that will be added to appPackage,
165165 // replacing any existing entries.
166- const templatePackageToReplace = Object . keys ( templatePackage ) . filter ( key => {
167- return (
168- ! templatePackageBlacklist . includes ( key ) &&
169- ! templatePackageToMerge . includes ( key )
170- ) ;
171- } ) ;
166+ const templatePackageToReplace = Object . keys ( templatePackage ) . filter (
167+ ( key ) => {
168+ return (
169+ ! templatePackageBlacklist . includes ( key ) &&
170+ ! templatePackageToMerge . includes ( key )
171+ ) ;
172+ }
173+ ) ;
172174
173175 // Copy over some of the devDependencies
174176 appPackage . dependencies = appPackage . dependencies || { } ;
@@ -206,7 +208,7 @@ module.exports = function(
206208 appPackage . browserslist = defaultBrowsers ;
207209
208210 // Add templatePackage keys/values to appPackage, replacing existing entries
209- templatePackageToReplace . forEach ( key => {
211+ templatePackageToReplace . forEach ( ( key ) => {
210212 appPackage [ key ] = templatePackage [ key ] ;
211213 } ) ;
212214
@@ -297,7 +299,7 @@ module.exports = function(
297299 } else {
298300 command = 'npm' ;
299301 remove = 'uninstall' ;
300- args = [ 'install' , '--save' , verbose && '--verbose' ] . filter ( e => e ) ;
302+ args = [ 'install' , '--save' , verbose && '--verbose' ] . filter ( ( e ) => e ) ;
301303 }
302304
303305 // Install additional template dependencies, if present
@@ -306,7 +308,7 @@ module.exports = function(
306308 templatePackage . dependencies || templateJson . dependencies ;
307309 if ( templateDependencies ) {
308310 args = args . concat (
309- Object . keys ( templateDependencies ) . map ( key => {
311+ Object . keys ( templateDependencies ) . map ( ( key ) => {
310312 return `${ key } @${ templateDependencies [ key ] } ` ;
311313 } )
312314 ) ;
@@ -330,7 +332,7 @@ module.exports = function(
330332 }
331333 }
332334
333- if ( args . find ( arg => arg . includes ( 'typescript' ) ) ) {
335+ if ( args . find ( ( arg ) => arg . includes ( 'typescript' ) ) ) {
334336 console . log ( ) ;
335337 verifyTypeScriptSetup ( ) ;
336338 }
0 commit comments