@@ -266,11 +266,12 @@ module.exports = async (api, options, rootOptions) => {
266266 await tsconfigSetup ( options , genConfig . dirPathPrefix , genConfig . nativeAppPathModifier ) ;
267267
268268 if ( fs . existsSync ( api . resolve ( 'tslint.json' ) ) ) {
269+ await tslintSetup ( genConfig . dirPathPrefix , api . resolve ( 'tslint.json' ) , genConfig . tsExclusionArray ) ;
270+
269271 const baseDir = genConfig . nativeAppPathModifier ;
270272 require ( '../lib/tslint' ) ( {
271273 '_' : [ `${ baseDir } **/*.ts` , `${ baseDir } **/*.vue` , `${ baseDir } **/*.tsx` , 'tests/**/*.ts' , 'tests/**/*.tsx' ]
272- } , api , true ) ;
273- tslintSetup ( genConfig . dirPathPrefix , api . resolve ( 'tslint.json' ) , genConfig . tsExclusionArray ) ;
274+ } , api , false ) ;
274275 }
275276 }
276277
@@ -720,7 +721,7 @@ const tslintSetup = (module.exports.tslintSetup = async (dirPathPrefix, tslintPa
720721// setup tsconfig for native only projects
721722const tsconfigSetup = ( module . exports . tsconfigSetup = async ( options , dirPathPrefix , nativeAppPathModifier ) => {
722723 try {
723- // setup the abilty to edit the tsconfig.json file in the root of the project
724+ // setup the ability to edit the tsconfig.json file in the root of the project
724725 let tsConfigContent = '' ;
725726 let tsConfigPath = path . join ( dirPathPrefix , 'tsconfig.json' ) ;
726727
@@ -735,6 +736,9 @@ const tsconfigSetup = (module.exports.tsconfigSetup = async (options, dirPathPre
735736 tsConfigContent . compilerOptions . noImplicitAny = false ;
736737 // // // tsConfigContent.compilerOptions.types = [];
737738
739+ // edit types attribute to fix build
740+ tsConfigContent . compilerOptions . types = [ 'node' ] ;
741+
738742 // edit some of the options in compilerOptions.paths object array
739743 tsConfigContent . compilerOptions . paths [ '@/*' ] = [ nativeAppPathModifier + '*' ] ;
740744 tsConfigContent . compilerOptions . paths [ 'assets/*' ] = [ nativeAppPathModifier + 'assets/*' ] ;
0 commit comments