stylelint-scss
stylelint-scss copied to clipboard
`Expected a pseudo-class or pseudo-element.` unwanted behaviour
Probably related to/caused by #359 fix. Throws unwanted error every time I want to add a pseudo-class selector before existing selector of any kind. Instead it should simply underline the problem and go away when the code is finished:
https://user-images.githubusercontent.com/5007456/114281630-aeba6380-9a3f-11eb-8336-517b851849da.mp4
I use v.3.19.
Thanks for reporting! I can reproduce the bug/error.
Here's the log from stylelint in vscode. Maybe this will help fix it:
(node:17428) UnhandledPromiseRejectionWarning: Error: Expected a pseudo-class or pseudo-element. at Root._error (c:\wamp64\www\chaosdesign\themes\chaosdesign_dev\node_modules\postcss-selector-parser\dist\parser.js:174:16) at Root.error (c:\wamp64\www\chaosdesign\themes\chaosdesign_dev\node_modules\postcss-selector-parser\dist\selectors\root.js:43:19) at Parser.error (c:\wamp64\www\chaosdesign\themes\chaosdesign_dev\node_modules\postcss-selector-parser\dist\parser.js:740:21) at Parser.expected (c:\wamp64\www\chaosdesign\themes\chaosdesign_dev\node_modules\postcss-selector-parser\dist\parser.js:1129:19) at Parser.pseudo (c:\wamp64\www\chaosdesign\themes\chaosdesign_dev\node_modules\postcss-selector-parser\dist\parser.js:895:19) at Parser.parse (c:\wamp64\www\chaosdesign\themes\chaosdesign_dev\node_modules\postcss-selector-parser\dist\parser.js:1080:14) at Parser.loop (c:\wamp64\www\chaosdesign\themes\chaosdesign_dev\node_modules\postcss-selector-parser\dist\parser.js:1039:12) at new Parser (c:\wamp64\www\chaosdesign\themes\chaosdesign_dev\node_modules\postcss-selector-parser\dist\parser.js:164:10) at Processor._root (c:\wamp64\www\chaosdesign\themes\chaosdesign_dev\node_modules\postcss-selector-parser\dist\processor.js:53:18) at c:\wamp64\www\chaosdesign\themes\chaosdesign_dev\node_modules\postcss-selector-parser\dist\processor.js:72:26 (node:17428) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag
--unhandled-rejections=strict
(see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 406)
Closing since it's probably caused by stylelint itself (npm package and/or vscode extension)