🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

postcss-discard-comments

Package Overview
Dependencies
Maintainers
8
Versions
61
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

postcss-discard-comments - npm Package Compare versions

Comparing version
7.0.5
to
7.0.6
+2
-2
package.json
{
"name": "postcss-discard-comments",
"version": "7.0.5",
"version": "7.0.6",
"description": "Discard comments in your CSS files with PostCSS.",

@@ -27,3 +27,3 @@ "main": "src/index.js",

"dependencies": {
"postcss-selector-parser": "^7.1.0"
"postcss-selector-parser": "^7.1.1"
},

@@ -30,0 +30,0 @@ "bugs": {

@@ -23,11 +23,11 @@ 'use strict';

let pos = 0;
let state = STATES.NORMAL;
let tokenStart = 0;
let commentStart = 0;
while (pos < length) {
const char = input[pos];
const nextChar = pos + 1 < length ? input[pos + 1] : '';
switch (state) {

@@ -50,3 +50,3 @@ case STATES.NORMAL:

break;
case STATES.IN_SINGLE_QUOTE:

@@ -61,3 +61,3 @@ if (char === '\\' && nextChar) {

break;
case STATES.IN_DOUBLE_QUOTE:

@@ -72,3 +72,3 @@ if (char === '\\' && nextChar) {

break;
case STATES.IN_COMMENT:

@@ -85,6 +85,6 @@ if (char === '*' && nextChar === '/') {

}
pos++;
}
// Handle remaining content

@@ -98,4 +98,4 @@ if (state === STATES.IN_COMMENT) {

}
return tokens;
};