Skip to content

JS source map broken in Safari with Angular CLI 1.4.2 #7724

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
waimun opened this issue Sep 17, 2017 · 9 comments
Closed

JS source map broken in Safari with Angular CLI 1.4.2 #7724

waimun opened this issue Sep 17, 2017 · 9 comments

Comments

@waimun
Copy link

waimun commented Sep 17, 2017

Bug Report or Feature Request (mark with an x)

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

Versions.

@angular/cli: 1.4.2
node: 6.11.3
os: darwin x64
@angular/animations: 4.4.1
@angular/common: 4.4.1
@angular/compiler: 4.4.1
@angular/core: 4.4.1
@angular/forms: 4.4.1
@angular/http: 4.4.1
@angular/platform-browser: 4.4.1
@angular/platform-browser-dynamic: 4.4.1
@angular/router: 4.4.1
@angular/cli: 1.4.2
@angular/compiler-cli: 4.4.1
@angular/language-service: 4.4.1
typescript: 2.3.4

Repro steps.

ng new --skip-install --skip-git --skip-commit my-dream-app
Edit package.json and add these entries under "devDependencies"
"bootstrap": "^4.0.0-beta",
"jquery": "^3.2.1",
"popper.js": "1.11.0"

Edit .angular-cli.json and add entry under "styles"
"../node_modules/bootstrap/dist/css/bootstrap.css",
"styles.css"

Add entry under "scripts" in the following order.
"../node_modules/jquery/dist/jquery.slim.js",
"../node_modules/popper.js/dist/umd/popper.js",
"../node_modules/bootstrap/dist/js/bootstrap.js"

Run npm install then ng serve

Open Safari, open inspector first (need to enable Developer menu in preferences if you don't have it initially) before going to http://localhost:4200/

You will see the 404 error for the missing http://localhost:4200/popper.js.map

Go to Chrome, open inspector first and go to http://localhost:4200/

You won't see the 404 error for the missing http://localhost:4200/popper.js.map

So this issue pertains to Safari browser only.

I found out about this error only after I upgraded from angular CLI 1.2.7 to 1.4.2. Try creating new app under CLI 1.27 version, repeating the same steps above, there is no 404 error about the popper.js.map.

I think something broke with the source maps in Safari. Could be similar issue with the issue #6697 but I am not sure if it is related.

The log given by the failure.

Failed to load resource: the server responded with a status of 404 (Not Found)
http://localhost:4200/popper.js.map

Desired functionality.

This 404 error should not appear as tested in CLI 1.2.7.

Mention any other details that might be useful.

I am using Safari Version 10.1.2 (12603.3.8) if that matters.

@skiabox
Copy link

skiabox commented Sep 20, 2017

I get the same exact error with safari 11.

@Brocco Brocco added P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent severity3: broken labels Sep 22, 2017
@filipesilva
Copy link
Contributor

This is related to the changes in #7279, but I need to investigate further what's going wrong. It should be a harmless 404 though, your application won't be affected by a missing sourcemap.

@waimun
Copy link
Author

waimun commented Sep 26, 2017

Agreed, it is a harmless bug and I deployed my application without any concerns at all.

@waimun
Copy link
Author

waimun commented Jan 2, 2018

As of today, I just verified that this bug is still valid with Angular CLI 1.6.3, the only thing different is it complains about missing bootstrap.js.map instead of popper.js.map after I upgraded bootstrap to 4.0.0-beta.2.

@dhniels
Copy link

dhniels commented Jan 18, 2018

I am having this issue as well.Safari (11.0.2) and Angular (5.0.0)

@filipesilva filipesilva added comp: cli/build and removed P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent severity3: broken labels Feb 14, 2018
@workfel
Copy link

workfel commented Mar 23, 2018

I am having the issue with Safari 10.1 , Angular 5.1.1, Angular cli 1.6.1

@waimun
Copy link
Author

waimun commented Mar 23, 2018

Looks like this is de-prioritized. Issue with Safari 11.0.3 , Angular 5.2 and CLI 1.7.3

@waimun
Copy link
Author

waimun commented May 29, 2018

This is finally fixed. I just verified with Angular 6.0.3 and Bootstrap 4.1.1. No longer giving 404 error about missing popper.js.map or bootstrap.js.map in Safari 11.1.

@waimun waimun closed this as completed May 29, 2018
@angular-automatic-lock-bot
Copy link

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.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants