Tool for checking unused CSS selectors?(检查未使用的 CSS 选择器的工具?)
问题描述
我知道有一个名为 Dust-Me Selectors for Firefox 的扩展,而且它不查看 JavaScript 生成的动态 HTML.
I know there is an extension called Dust-Me Selectors for Firefox and also that it doesn't look at dynamic HTML generated by JavaScript.
我正在寻找可以从样式表中识别所有未使用的选择器的工具,这些选择器附加到多个页面,并且所有 JavaScript 都在运行并检查选择器?我现在知道的唯一选择是手动检查文件并找到未使用的选择器:(
I'm looking for tool(s) that can identify all unused selectors from a stylesheet, attached to several pages, with all the JavaScript running and checking selectors? The only option I know right now for this is manually checking files and finding unused selectors :(
在 IDE 中 - 我相信 NetBeans 在编写 Java 代码时会在未使用库时提供警告消息.如果没有 IDE(NetBeans、Eclipse、Dreamweaver 等)插件来搜索选择器,我的选择是什么?
In IDE's - I believe NetBeans provides a warning message when writing Java code, if a library is not under use. Without an IDE (NetBeans, Eclipse, Dreamweaver, etc) plugin to search for the selectors what are my options?
另外,是否有工具可以检查同一文件中未使用的选择器.我的意思是如果所有的 JS、HTML 和 CSS 代码都在同一个文件中.
Also, is there a tool to check for unused selectors in the same file. I mean if all the JS, HTML and CSS code is in the same file.
推荐答案
我认为 http://unused-css.com 会做你想做的事.
I think that http://unused-css.com will do exactly what you want.
https://github.com/geuis/helium-css可以帮忙
以及:http://razorfast.com/2010/11/21/announcing-cssess-the-bookmarklet-that-finds-unused-css-selectors/
这篇关于检查未使用的 CSS 选择器的工具?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:检查未使用的 CSS 选择器的工具?
- Quasar 2+Apollo:错误:找不到ID为默认的Apollo客户端。如果您在组件设置之外,请使用ProvideApolloClient() 2022-01-01
- Css:将嵌套元素定位在父元素边界之外一点 2022-09-07
- addEventListener 在 IE 11 中不起作用 2022-01-01
- CSS媒体查询(最大高度)不起作用,但为什么? 2022-01-01
- 使用RSelum从网站(报纸档案)中抓取多个网页 2022-09-06
- 如何使用 JSON 格式的 jQuery AJAX 从 .cfm 页面输出查 2022-01-01
- Flexslider 箭头未正确显示 2022-01-01
- Fetch API 如何获取响应体? 2022-01-01
- 400或500级别的HTTP响应 2022-01-01
- 失败的 Canvas 360 jquery 插件 2022-01-01
