fix(web-app): replace removed stylelint --syntax flag#4241
Merged
tomsun28 merged 2 commits intoJul 25, 2026
Conversation
stylelint 14 removed the --syntax option, so lint:style crashed before linting anything. Use customSyntax with postcss-less (postcss 8 compatible) instead.
orangeCatDeveloper
force-pushed
the
fix/issue-3728-stylelint-syntax
branch
from
July 24, 2026 08:44
6b8d3d7 to
4b3e72a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Close #3728
What's changed
npm run lint:stylecrashed immediately with:stylelint 14 removed the
--syntaxCLI flag, but thelint:stylescript stillpassed
--syntax less, so the command errored out before linting anything.Fix, following stylelint's own migration guidance:
package.json: drop the removed--syntax lessflag fromlint:style..stylelintrc: declare"customSyntax": "postcss-less"(applies to everyinvocation, incl. lint-staged and IDE integrations).
postcss-less@6.0.0— the postcss 8 compatible line (stylelint 14 usespostcss 8; the older 3.1.4 requires postcss 7 and would mismatch).
Test plan
cd web-app && npm run lint:styleThe "syntax" option is no longer available..lessfiles (exits with the existingstyle violations instead of crashing).
Note
Once the command runs, it surfaces a backlog of pre-existing
.lessstyleviolations. Those are unrelated to this change and
lint:styleis not currentlywired into CI or a pre-commit hook, so they block nothing. Cleaning them up (and
optionally enforcing the lint) is left as a separate follow-up.