dotenv-run icon indicating copy to clipboard operation
dotenv-run copied to clipboard

long time recompilation

Open BrothersWar opened this issue 2 years ago • 7 comments

When i use:

        "build": {
          "builder": "@ngx-env/builder:browser",
         }

instead of my:

        "build": {
          "builder": "@angular-devkit/build-angular:browser",
         }

recompilation takes about a minute each time. in serve i can use:

        "serve": {
          "builder": "@ngx-env/builder:dev-server",
         }

and everything okay. But i need to use builder to deploy my code to production. Any ideas? I tried on 1.1.0 version and 2.0.0 versions. Angular 11

BrothersWar avatar Dec 01 '21 09:12 BrothersWar

Could you please put the build outputs with and without @ngx-env/builder here?

chihab avatar Dec 01 '21 16:12 chihab

i add:

              "buildOptimizer": false,
              "optimization": false,

to my:

 "configurations": {
            "development": {
              "statsJson": true,
              "sourceMap": true,
              "buildOptimizer": false,
              "optimization": false,
              "vendorChunk": true,
              "namedChunks": true,
              "extractLicenses": false
            },

and everything now works fine

BrothersWar avatar Dec 01 '21 19:12 BrothersWar

I also notice that, it optimizes the code but the default behavior of @angular-devkit/build-angular:browser. It is possible to match the default behavior of @angular-devkit/build-angular:browser for the different configurations? Also show this message image

j-perezr avatar Dec 16 '21 20:12 j-perezr

Thanks for confirming the issue @jperezruiz. I was able to reproduce it on v11 with v1.1.0. I am looking into it.

chihab avatar Dec 18 '21 09:12 chihab

Thank you! If I can help please tell me

j-perezr avatar Dec 18 '21 10:12 j-perezr

Any update on this one?

y4nnick avatar Apr 23 '22 23:04 y4nnick

When i develop with Hot Module Replacement mode, the recompiling is also much more slowly.

loclv avatar Sep 26 '22 01:09 loclv

Closing the issue as this way for old v11 versions. Let me know if you still have it with newer Angular versions.

chihab avatar Jan 06 '23 09:01 chihab

@chihab I am using the : "@ngx-env/builder : "^15.2.1".

When executing the command "ng test" it is super slow compared to "build-angular:karma".

jimyhdolores avatar Jul 04 '23 17:07 jimyhdolores