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 14 Upgrade, removing deployUrl as a build option causing fail in loading chunk files from subfolder

See original GitHub issue

Which @angular/* package(s) are the source of the bug?

compiler-cli

Is this a regression?

No

Description

We have a scenario where we deploy the UI code under the subfolder wwwroot/approot in IIS server, we are using deployUrl as 'approot ’ to load the lazy loaded chunk files. When we upgrade the Angular 14, deployUrl is deprecated and if we use baseHref, it’s failing to load the chunk files. It’s trying to load the chunk files from the main root i.e webroot but the files are under wwwroot/approot. I couldn’t find any solution to acheive this without deployUrl.

Please provide a link to a minimal reproduction of the bug

No response

Please provide the exception or error you saw

No response

Please provide the environment you discovered this bug in (run ng version)

Angular CLI: 14.0.6
Node: 16.12.0
Package Manager: npm 8.1.0
OS: win32 x64

Anything else?

No response

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:9

github_iconTop GitHub Comments

1reaction
kiranahidcommented, Jul 22, 2022

As you have suggested, using @angular-builders/custom-webpack:browser and setting the publicPath in custom webconfig file resolved the issue. Thanks for your suggestions @alan-agius4 .

0reactions
angular-automatic-lock-bot[bot]commented, Aug 22, 2022

This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

Read more comments on GitHub >

github_iconTop Results From Across the Web

What is best way to go about replacing 'deployUrl' in angular ...
Ended up finding something to replace this with: Replaced "deployUrl" with "baseHref" in angular.json; Added the APP_BASE_HREF override in ...
Read more >
single-spa-angular
To build your Angular CLI application as a single-spa app do the following. Open angular.json; Locate the project you wish to update. Navigate...
Read more >
How to Solve the Chunk Load Error in JavaScript - Rollbar
Whenever there's an error observed in dynamically fetching helper JavaScript files known as Chunks, a ChunkLoad Error is thrown.
Read more >
angular build watch Code Example - Code Grepper
Answers related to “angular build watch”. angular build production · ng build prod · build angular project · angular deployment · how to...
Read more >
Public Release Notes - Intershop Progressive Web App
Angular 14 and dependecies update (see Migrations / 2.4 to 3.0 for more ... repair chunk output file names for differential loading (#896)...
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