6

We have updated an Angular app from version 7.2 to version 8. The update process has worked so far and the app can be used locally and in prod mode (on the server) on Chrome, Firefox Developer Edition, Safari, Opera as usual.

But in the normal Firefox browser and Waterfox, the app does not work:

  • The app tries to render while the browser shows the status "Performing a tls handshake to localhost", until at some point a "The connection has timed out" comes.
  • In prod mode, after I have deployed the app, at least the login mask shows up but the performance of the app is so bad that hardly nothing works.

We have created a browserlist file with the following content:

# This file is used by the build system to adjust CSS and JS output to support the specified browsers below.
# For additional information regarding the format and rule options, please see:
# https://github.com/browserslist/browserslist#queries

# You can see what browsers were selected by your queries by running:
# npx browserslist

> 0.5%
last 2 versions
Firefox ESR
not dead
not IE 9-11 # For IE 9-11 support, remove 'not'.

Our tsconfig looks like this:

{
  "compileOnSave": false,
  "compilerOptions": {
    "downlevelIteration": true,
    "importHelpers": true,
    "outDir": "./dist/out-tsc",
    "baseUrl": "src",
    "sourceMap": true,
    "declaration": false,
    "moduleResolution": "node",
    "emitDecoratorMetadata": true,
    "experimentalDecorators": true,
    "target": "es2015",
    "typeRoots": [
      "Node_modules / @ types"
    ]
    "lib": [
      "ES2016"
      "Dom"
    ]
    "module": "esnext"
  }
}

And the area with the ssl configuration inside the angular.json so:

  "serve": {
    "builder": "@angular-devkit/build-angular:dev-server",
    "options": {
      "browserTarget": "farm-management-ui:build",
      "port": 8080,
      "ssl": true,
      "proxyConfig": "src/proxy.conf.js"
    },

We have already successfully executed the following commands:

ng update @ angular / cli --from 7 --to 8 --migrate - only

ng update @ angular / core - from 7 - to 8 --migrate-only

And I have the feeling that if the app is running in Firefox an endless loop is created, because I can't also open other webpages like Stackoverflow and so on..

Why does Firefox suddenly have this behavior and how can we fix this?

4
  • 1
    What is your typescript and node version ? Commented Jul 1, 2019 at 11:14
  • 1
    @SrishtiKhandelwal Typescript Version 3.4.5 | Node Version v12.4.0 | npm Version 6.9.0
    – Codehan25
    Commented Jul 1, 2019 at 11:17
  • 1
    Try to check if you missed anything. Refer update.angular.io/#7.2:8.0 Commented Jul 1, 2019 at 15:39
  • I did that 3 or 4 times. Nothing is missing from that guide.
    – Codehan25
    Commented Jul 3, 2019 at 13:58

2 Answers 2

3

Changing in tsconfig.json the property target from es2015 to old value es5, application works.

2
  • That worked for me, thanks. I wonder what ES2015 feature FireFox is missing so that is requires a "deeper" polyfill layer? Is there any negative impact for Chrome and Edge? Commented Dec 29, 2019 at 21:40
  • This did not work for me.
    – ijt
    Commented Feb 8, 2023 at 4:59
-1

Try this command in terminal

npm i zone.js@latest

After this i can run my app on Firefox

1
  • This also did not work for me.
    – ijt
    Commented Feb 8, 2023 at 5:01

Not the answer you're looking for? Browse other questions tagged or ask your own question.