question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Angular 6.04 ,building sourceMap cause ng serve slow

See original GitHub issue

Bug Report or Feature Request (mark with an x)

- [ x] bug report -> please search issues before submitting
- [ ] feature request

Command (mark with an x)

- [ ] new
- [ ] build
- [x ] serve
- [ ] test
- [ ] e2e
- [ ] generate
- [ ] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc

Versions

Angular CLI: 6.1.2 Node: v8.11.3 npm: 6.2.0

Repro steps

### " 92% after chunk asset optimization SourceMapDevToolPlugin main.js generate SourceMap " too slow

After upgrade angular to 6.04, ng serve takes 5 minutes building source map.( SourceMapDevToolPlugin is very slow). Modifying source code take 5 minutes to regenerate source map too.

Is there any way to decrease the time building source map during ng serve ? I don’t want to use --source-map=false option. use --max-old-space-size does not do any help.

The log given by the failure

Desired functionality

Mention any other details that might be useful

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:15 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
aljasPODcommented, Sep 4, 2018

For us the new webpack-sources update seems to improve the speed:

Initial build is back to the previous performance:

Time: 56654ms
chunk {main} main.js, main.js.map (main) 7.14 MB [initial] [rendered]
chunk {polyfills} polyfills.js, polyfills.js.map (polyfills) 420 kB [initial] [rendered]
chunk {runtime} runtime.js, runtime.js.map (runtime) 5.22 kB [entry] [rendered]
chunk {styles} styles.js, styles.js.map (styles) 239 kB [initial] [rendered]
chunk {vendor} vendor.js, vendor.js.map (vendor) 4.15 MB [initial] [rendered]
i ?wdm?: Compiled successfully.

Rebuild is still a bit slower, but I’d say it’s now in the acceptable region:

Date: 2018-09-04T13:48:10.374Z - Hash: 4799daa924af20604696 - Time: 14137ms
4 unchanged chunks
chunk {main} main.js, main.js.map (main) 7.14 MB [initial] [rendered]
i ?wdm?: Compiled successfully.
1reaction
clydincommented, Sep 6, 2018

Also a quick note that 1.2.0 will be the minimum required version in CLI 7.0.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Incredibly slow Angular source map build - node.js
In an effort to debug a production Angular issue, I'm trying to generate a source map for the project. As suggested on a...
Read more >
A small tip to speed up development with Angular or Ionic
This is mostly because of bulky source map files. When you do ng serve , Angular serves the app from memory instead of...
Read more >
ng serve - slow as hell! : r/Angular2
I've just updated my major project to v12 and I'm running ng serve to view css changes but it's taking too long to...
Read more >
NG SERVE very slow #5330
Hi, I've upgraded my existing project from v5.1 to v5.5. Webpack build is very long the first time ; it takes more than...
Read more >
https://packages.ubuntu.com/km/source/jammy/s390x/...
... [universe] apt (2.4.5) apt-btrfs-snapshot (3.5.5) [universe] apt-build (0.12.49) [universe] apt-cacher (1.7.25) [universe] apt-cacher-ng (3.7.4-1build1) ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found