Introducing Socket Firewall: Free, Proactive Protection for Your Software Supply Chain.Learn More
Socket
Book a DemoInstallSign in
Socket

selector-detector

Package Overview
Dependencies
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

selector-detector

CLI tool to count the CSS rules, selectors and declarations on a web page.

latest
Source
npmnpm
Version
1.1.4
Version published
Weekly downloads
7
-93%
Maintainers
1
Weekly downloads
 
Created
Source

NPM version Dependency Status Downloads

selector-detector

Counts the CSS rules, selectors and declarations on a web page as well as the total number of inline style blocks and linked stylesheets.

Internet Explorer version 9 and below have a limit on the number of CSS rules & selectors they can parse. Once it reaches that limit, it will fail silently and ignore any further CSS declarations which result in aspects of the page not having styling applied. Additionally, those versions of IE will also fail to parse any stylesheets after the 31st (inline style blocks count towards this total).

Internet Explorer (9 and below) Rules:

  • All style tags after the first 31 style tags are not applied.
  • All style rules after the first 4,095 rules are not applied.
  • On pages that uses the @import rule to continuously import external style sheets that import other style sheets, style sheets that are more than three levels deep are ignored.

source

Usage

  $ selector-detector http://www.google.com

Installation

Installing via npm (node package manager)

  $ [sudo] npm install -g selector-detector

Clone & Hack

The source is available for download from GitHub.

  $ git clone git@github.com:okize/selector-detector.git && cd selector-detector
  $ npm install

License

Released under the MIT License.

Keywords

css

FAQs

Package last updated on 09 May 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts