Source map reference fails in Edge/IE 11
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 55/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Stale
- Tech stack
- javascript
- Domain
- build-system
Research direction
Start with the clean-css plugin path exercised by lessc --source-map --clean-css main.less main.css, then inspect how the CSS output appends the source map comment. Done means the generated main.css places the comment after a newline and Edge requests main.css.map while showing main.less in the Styles panel.
Written by the indexing model from the issue text.
Description
Problem
Microsoft Edge doesn't attempt to load the .map file due to the location of the source map comment in the CSS output.
This is somewhat a known phenomenon (with both CSS and JavaScript): https://stackoverflow.com/q/34687049/404623
Reproduce
main.less
html{color:red}
body{color:blue}
index.html
<!DOCTYPE html>
<link rel=stylesheet type=text/css href=main.css>
<p>Hello world</p>
Run lessc with the clean-css plugin:
lessc --source-map --clean-css main.less main.css
Output (main.css)
html{color:red}body{color:#00f}/*# sourceMappingURL=main.css.map */
Upon loading index.html in Microsoft Edge and opening Debugger in the F12 Developer Tools, there is no request made to the server for the map file, and inspect element shows main.css references in the Styles panel instead of main.less
Expected results
Edge should attempt to load the main.css.map file and refer to the code in the main.less file in the Styles panel in the F12 Developer Tools.
Expected output of main.css (note the newline)
html{color:red}body{color:#00f}
/*# sourceMappingURL=main.css.map */
Manually editing the files to add the newline character fixes the problem but defeats the purpose of the build tool.
- Dominant language
- JavaScript
- Stars
- 193
- Forks
- 41
- Avg merge
- 8h 15m
- Merged PRs (30d)
- 4
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from less/less-plugin-clean-css
-
Difficulty 3/5 1-2 days Newbie friendliness 55/100
-
Difficulty 3/5 1-2 days Newbie friendliness 28/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 35/100
less/less-plugin-clean-css#42 · 1 comment · 2 reactions ·
-
ReleaseOpen
Difficulty 4/5 3-5 days Newbie friendliness 20/100
less/less-plugin-clean-css#40 · 9 comments · 1 reaction ·
-
Difficulty 3/5 1-2 days Newbie friendliness 38/100
All issues in less/less-plugin-clean-css
Similar issues
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
jspreadsheet/ce#1809 ·
-
documentation
Difficulty 1/5 Under an hour Newbie friendliness 91/100
githubnext/gh-aw-workshop#4458 ·
Maintainers usually reply within 1 day
-
Add: CartoonitoOpencheck:failed feeds:add
Difficulty 2/5 1-3 hours Newbie friendliness 63/100
iptv-org/database#37390 · 1 comment ·
Maintainers usually reply within 9 days
-
bug: directory index route root priority is overwritten when wildcard is falsePossibly taken @TalhaHunter101 claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
fastify/fastify-static#617 ·
-
bug confirmed css v6
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
Maintainers usually reply within 1 day