diff --git a/__tests__/__snapshots__/comment.js.snap b/__tests__/__snapshots__/comment.js.snap index 8f97288..5c01655 100644 --- a/__tests__/__snapshots__/comment.js.snap +++ b/__tests__/__snapshots__/comment.js.snap @@ -34,6 +34,13 @@ Array [ 1, 14, ], + Array [ + "newline", + " +", + 2, + 0, + ], ] `; @@ -175,6 +182,13 @@ Array [ 5, 3, ], + Array [ + "newline", + " +", + 6, + 0, + ], ] `; @@ -226,6 +240,13 @@ Array [ 3, 2, ], + Array [ + "newline", + " +", + 4, + 0, + ], ] `; @@ -271,5 +292,12 @@ Array [ 1, 16, ], + Array [ + "newline", + " +", + 2, + 0, + ], ] `; diff --git a/src/tokenize.js b/src/tokenize.js index 56feb2a..a074874 100644 --- a/src/tokenize.js +++ b/src/tokenize.js @@ -200,7 +200,7 @@ export default function tokenize(input, l, p) { if ( inComment && code === asterisk && css.charCodeAt(pos + 1) === slash ) { inComment = false; tokens.push(['endComment', '*/', line, pos + 1 - offset]); - pos += 2; + pos += 1; break; }