chore(linters): update stylelint, enable linters in github actions#39
chore(linters): update stylelint, enable linters in github actions#39baevm wants to merge 2 commits intoconsta-design-system:devfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates the frontend linting toolchain (Stylelint/Prettier + related ESLint packages), aligns Stylelint configuration with the new versions, and wires linting/typecheck into GitHub Actions CI. It also includes formatting-only code/CSS changes to satisfy the updated linters.
Changes:
- Upgraded Stylelint/Prettier and related lint deps; adjusted
.stylelintrc.jsrules for the new Stylelint baseline. - Added non-fixing and fixing variants for JS/CSS lint scripts in
package.json. - Updated CI workflow to run TypeScript check, unit tests, and linting; applied formatting fixes across TS/CSS/MDX.
Reviewed changes
Copilot reviewed 17 out of 19 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
yarn.lock |
Regenerated lockfile for updated linting/formatting dependencies. |
package.json |
Bumped lint/format deps; split lint scripts into check vs fix variants. |
.stylelintrc.js |
Updated/relaxed rules to be compatible with newer Stylelint + project CSS patterns. |
.github/workflows/tests.yml |
CI now runs TS check, unit tests, and linting (in addition to dependency install changes). |
src/utils/type-guards.ts |
Minor TS cleanup: removed unused generic on isFunction. |
src/utils/object/get/get.ts |
Formatting-only indentation fix. |
src/utils/array.ts |
Formatting-only change for groupBy implementation. |
src/utils/__tests__/array.test.ts |
TS type expression formatting fix. |
src/components/Pagination/Pagination.tsx |
Removed unused setter variables from useAtom destructuring. |
src/components/Toolbar/Toolbar.css |
Stylelint-driven formatting changes to declarations. |
src/components/TextFieldCell/TextFieldCell.css |
Reordered/adjusted declarations per lint rules. |
src/components/Table/TableRow/TableRow.css |
Reformatted complex color-mix(...) custom property values. |
src/components/Table/TableResizers/TableResizers.css |
Reformatted calc(...) custom properties/declarations. |
src/components/Table/TableData/TableData.css |
Reformatted complex color-mix(...) custom property values. |
src/components/Table/TableCell/TableCell.css |
Reformatted multi-value box-shadow declaration. |
src/components/Table/helpers.ts |
Added parentheses for clarity in nullish-coalescing expression. |
src/components/DataCell/DataCell.css |
Removed blank line; added rule-disable comment for deprecated word-break value. |
src/components/Collapse/__stand__/examples/CollapseExampleFullscreenContainer/CollapseExampleFullscreenContainer.css |
Replaced grid-gap with gap; reformatted calc(...) expression. |
src/components/Collapse/__stand__/Collapse.dev.stand.mdx |
Kept MDX snippet consistent with the updated CSS formatting (gap, calc(...)). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| @@ -35,5 +35,9 @@ jobs: | |||
| ${{ runner.os }}-yarn- | |||
| - name: Установка зависимостей | |||
| run: yarn add "install-peers-cli@https://github.com/evless/install-peers-cli#fix-yarn-policies" && yarn --frozen-lockfile | |||
There was a problem hiding this comment.
The workflow installs dependencies by running yarn add "install-peers-cli@...#fix-yarn-policies" inside CI. This mutates package.json/yarn.lock during the job and means CI is no longer validating the dependency graph that’s actually committed (and it adds extra network/registry variability). Prefer pinning the required install-peers-cli source in package.json (e.g., update the dependency to the GitHub URL or a published version) and then using a plain yarn --frozen-lockfile here.
| run: yarn add "install-peers-cli@https://github.com/evless/install-peers-cli#fix-yarn-policies" && yarn --frozen-lockfile | |
| run: yarn --frozen-lockfile |
Описание изменений
Обновил stylelint и prettier. Добавил запуск линтеров в CI. Исправил линт ошибки. Конфиг для stylelint использовал из основного репозитория
Чек-лист
Опционально