.
├── bootstrap.css
├── bootstrap.css.map
├── bootstrap.min.css
├── bootstrap-theme.css
├── bootstrap-theme.css.map
└── bootstrap-theme.min.css
0 directories, 6 files
在下载最新的bootstrap后,发现*.map后缀结束的文件,这个文件有何意义?为什么会产生这种文件,我该怎么用起来?
.
├── bootstrap.css
├── bootstrap.css.map
├── bootstrap.min.css
├── bootstrap-theme.css
├── bootstrap-theme.css.map
└── bootstrap-theme.min.css
0 directories, 6 files
在下载最新的bootstrap后,发现*.map后缀结束的文件,这个文件有何意义?为什么会产生这种文件,我该怎么用起来?
对于js的map是为了对应到压缩前的代码,比如那些a,b之类的
但是,对于css.map
是和css预处理器相关的
Many developers generate CSS style sheets using a CSS preprocessor, such as Sass, Less, or Stylus. Because the CSS files are generated, editing the CSS files directly is not as helpful.
For preprocessors that support CSS source maps, DevTools lets you live-edit your preprocessor source files in the Sources panel, and view the results without having to leave DevTools or refresh the page. When you inspect an element whose styles are provided by a generated CSS file, the Elements panel displays a link to the original source file, not the generated .css file.
详细内容见:
https://developer.chrome.com/devtools/docs/css-preprocessors
10 回答11.3k 阅读
5 回答4.9k 阅读✓ 已解决
4 回答3.2k 阅读✓ 已解决
2 回答2.8k 阅读✓ 已解决
3 回答5.2k 阅读✓ 已解决
1 回答3.4k 阅读✓ 已解决
3 回答2.4k 阅读✓ 已解决
参考
http://www.ruanyifeng.com/blog/2013/01/javascript_source_map.html
http://segmentfault.com/q/1010000000259052