Bootstrap 3.x 中使用的 .map 文件是什么? [英] what are the .map files used for in Bootstrap 3.x?

查看:44
本文介绍了Bootstrap 3.x 中使用的 .map 文件是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

CSS 文件夹中包含两个文件扩展名为 .map 的文件.它们是:

There are two files included in the CSS folder with .map file extensions. They are:

bootstrap-theme.css.map
bootstrap.css.map

它们似乎是缩小的文件,但我不知道它们的用途.

They appear to be minified files but I don't know what they are for.

推荐答案

来自 在 Chrome DevTools 中使用 CSS 预处理器:

许多开发人员使用 CSS 预处理器(例如 Sass、Less 或 Stylus)生成 CSS 样式表.因为生成了 CSS 文件,所以直接编辑 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.

对于支持 CSS 源映射的预处理器,DevTools 允许您在 Sources 面板中实时编辑预处理器源文件,无需离开 DevTools 或刷新页面即可查看结果.当您检查样式由生成的 CSS 文件提供的元素时,元素"面板会显示指向原始源文件的链接,而不是生成的 .css 文件.

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.

这篇关于Bootstrap 3.x 中使用的 .map 文件是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆