Closed (fixed)
Project:
Open Atrium
Version:
7.x-2.68
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
2 Sep 2016 at 23:58 UTC
Updated:
3 Nov 2016 at 13:54 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
socialnicheguru commentedComment #3
mpotter commentedFortunately this doesn't affect the actual operation of the site. It's only used by the browser when you want to debug the javascript that is minimized.
But yes, we recently changed our local scripts for compiling the theme/css/js code and looks like we didn't enable the option to strip out the re
Comment #4
Argus commentedSo is this patch applicable?
Comment #5
mpotter commentedNot really. I mean, it's a temp fix for people, but the *.min.js files are generated via our build process that compiles the css, performs linting, compresses, etc. Somewhere there is a config setting that would tell it not to add the map files, but I haven't touched the frontend tools in a while so would take some investigating. See the docs in the oa_basetheme readme on how the tools are setup.
Comment #6
jeffm2001 commentedWhy not just include the source map files? That was the approach taken in core: #2400675: Missing .map files causing 404 file not found errors
There's a line in .gitignore
assets/*/*.map. (This happens for CSS too, btw). Is there some reason those files shouldn't exist on production sites?Comment #7
mpotter commentedThe reason .gitignore has entries for the *.map files is because small changes in either the css or js cause these map files to change and generates large "diffs" that make creating clean patches very difficult. It also makes team development difficult because you can run into more merge conflicts with map files. It is a normal "best practice" with version control to not include compiled assets like map files, or even the .min files themselves in many cases.
Also, the Core issue you referenced is from over a year ago. The current base-practice in D8 (and backporting to D7) is to remove the sourceMappingURL as mentioned in this issue: #2400287: Remove all occurences of sourceMappingURL and sourceURL when JS files are aggregated
Comment #8
mpotter commentedI've manually removed the sourceMappingURL lines in both css and js for oa_basetheme and oa_theme. Added a PR to our front-end tools to add an option for the future. Until that gets done I'll try to remember to remove these lines manually after recompiling the sass files.