Skip to content

fix(eslint-plugin): make rules and recommended() assignable to ESLint's types - #3981

Merged
segunadebayo merged 4 commits into
chakra-ui:v2from
sangwook-dev:fix/eslint-plugin-eslint-types
Oct 13, 2026
Merged

segunadebayo merged 4 commits into
chakra-ui:v2from
sangwook-dev:fix/eslint-plugin-eslint-types

Conversation

@sangwook-dev

Copy link
Copy Markdown
Contributor

Closes #3979

๐Ÿ“ Description

recommended() and the plugin's rules now type-check against ESLint's own types, so eslint.config.ts no longer
needs a cast.

โ›ณ๏ธ Current behavior (updates)

In a type-checked eslint.config.ts, defineConfig([await panda.configs.recommended(...)]) fails with TS2322. Linting
works. Only the types disagree, in three places, and tsc shows just the first:

  • fix and suggest[].fix return unknown. ESLint expects a fix object or null.
  • ReportDescriptor.loc is optional. ESLint requires node or loc.
  • SourceCodeLike has only optional fields, so ESLint's BinarySourceCode (which has body, not text) shares no
    property with it.

๐Ÿš€ New behavior

  • Fixers return RuleTextEdit | null, the { range, text } shape ESLint and oxlint both use.
  • loc is required.
  • SourceCodeLike gains body?: Uint8Array, so both members of ESLint's SourceCode union fit.
  • One runtime change: extraction-diagnostics reports a diagnostic without a location on line 1, like
    file-not-included. Before, that report had neither node nor loc, and ESLint throws on it.
  • The rule tester no longer needs as unknown as RuleDefinition.

๐Ÿ’ฃ Is this a breaking change (Yes/No):

No. The exported ReportDescriptor now requires loc; every built-in rule already passes it.

๐Ÿ“ Additional Information

  • Tests: __tests__/eslint-types.test.ts is compile-time only and runs under pnpm typecheck. It fails with 3 errors
    before this change. __tests__/report-diagnostics.test.ts checks that a diagnostic without a location lands on
    line 1. Before this change, ESLint throws instead.
  • Checks: pnpm typecheck, pnpm --filter @pandacss/eslint-plugin test (17 files, 154 tests), eslint, prettier. CI
    doesn't run the eslint-plugin Vitest suite (the root config excludes it), so the runtime test only runs locally.
  • The repro from [eslint-plugin] recommended() fails type-checking in eslint.config.ts (TS2322)ย #3979 against this build has 0 errors on ESLint 9.39.5 and 10.12.0 with TypeScript 6.0.3, also with
    --strict.

โ€ฆ's types

In a type-checked eslint.config.ts, `defineConfig([await recommended()])`
failed with TS2322. Three plugin types disagreed with ESLint's: fixers
returned `unknown`, `loc` was optional although ESLint requires `node` or
`loc`, and `SourceCodeLike` shared no property with ESLint's
`BinarySourceCode`.

One runtime change: extraction-diagnostics now reports a diagnostic without
a location on line 1, like file-not-included. Before, that report had
neither `node` nor `loc`, which ESLint rejects with an assertion error.
@changeset-bot

changeset-bot Bot commented Oct 11, 2026 •

Copy link
Copy Markdown

๐Ÿฆ‹ Changeset detected

Latest commit: 20af859

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 21 packages
Name Type
@pandacss/eslint-plugin Patch
@pandacss/bun Patch
@pandacss/cli Patch
@pandacss/compiler-shared Patch
@pandacss/compiler-wasm Patch
@pandacss/compiler Patch
@pandacss/config Patch
@pandacss/dev Patch
@pandacss/mcp Patch
@pandacss/postcss Patch
@pandacss/preset-base Patch
@pandacss/preset-panda Patch
@pandacss/preset-typography Patch
@pandacss/rollup Patch
@pandacss/transformer Patch
@pandacss/types Patch
@pandacss/vite Patch
@pandacss/webpack Patch
studio Patch
playground Patch
website Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel

vercel Bot commented Oct 11, 2026

Copy link
Copy Markdown

@Han5991 is attempting to deploy a commit to the Chakra UI Team on Vercel.

A member of the Team first needs to authorize it.

@sangwook-dev
sangwook-dev marked this pull request as ready for review October 11, 2026 11:31
@segunadebayo
segunadebayo merged commit 78eed7e into chakra-ui:v2 Oct 13, 2026
0 of 3 checks passed
@sangwook-dev
sangwook-dev deleted the fix/eslint-plugin-eslint-types branch October 13, 2026 08:28
sangwook-dev added a commit to sangwook-dev/fe-lab that referenced this pull request Oct 22, 2026
* build(deps): Panda CSS๋ฅผ 2.3.0์œผ๋กœ ์˜ฌ๋ฆฐ๋‹ค

@pandacss/{dev,preset-base,preset-panda,vite}์™€ catalogs.lint์˜ @pandacss/eslint-plugin์„
2.1.2์—์„œ 2.3.0์œผ๋กœ ํ•จ๊ป˜ ์˜ฌ๋ฆฐ๋‹ค.

- ๋ธ”๋กœ๊ทธ out/ CSS๋Š” 2.1.2์™€ ๊ฐ™๋‹ค(.nextยทout์„ ์ง€์šด ๊ฐ•์ œ ๋นŒ๋“œ ๋‘ ๋ฒˆ์„ ๋น„๊ต, ์†Œ์Šค๋งต ์ด๋ฆ„๋งŒ ๋‹ค๋ฅด๋‹ค).
- 2.3.0๋ถ€ํ„ฐ Panda lint์˜ no-invalid-token-paths๊ฐ€ ์Šคํƒ€์ผ ๋ฌธ์ž์—ด ์•ˆ์˜ ์—†๋Š” ํ† ํฐ
  (`'1px solid token(colors.orange.500)'`)์„ ์žก๋Š”๋‹ค(chakra-ui/panda#3996). ๋ธ”๋กœ๊ทธ src/์—
  ๋„ฃ์–ด ๋ฐœํ™”๋ฅผ ๋ณด๊ณ  ์›๋ณตํ–ˆ๋‹ค. AGENTS.md ยง3์˜ "์–ด๋А ์ชฝ๋„ ๋ณด์ง€ ์•Š๋Š”๋‹ค"๋ฅผ ๋ฒ”์œ„์™€ ํ•จ๊ป˜ ๊ณ ์นœ๋‹ค โ€”
  check-types๋Š” ์—ฌ์ „ํžˆ ๋ชป ๋ณด๊ณ , lint๋„ ๋ธ”๋กœ๊ทธ src/๋งŒ ๋ณธ๋‹ค(panda.config.ts์˜ globalCssยทlab ์•ฑ์€ ๋ฐ–).

* strict(blog-web): Panda lint ์„ค์ •์€ ๋‹จ์–ธยทํŒŒ์ผ ์˜ˆ์™ธ ์—†์ด ํ”Œ๋Ÿฌ๊ทธ์ธ์˜ ํƒ€์ž…๊ณผ ํŒ์ •์„ ๊ทธ๋Œ€๋กœ ์“ด๋‹ค

2.3.0์— ๋“ค์–ด๊ฐ„ upstream ์ˆ˜์ • ๋‘˜๋กœ 2.1.2์šฉ ์šฐํšŒ๋ฅผ ๊ฑท๋Š”๋‹ค.

- recommended()๊ฐ€ ESLint์˜ defineConfig ํƒ€์ž…์— ๊ทธ๋Œ€๋กœ ๋“ค์–ด๊ฐ„๋‹ค(chakra-ui/panda#3981).
  `as unknown as Linter.Config` ๋‹จ์–ธ๊ณผ, ๊ทธ ๋‹จ์–ธ ๋•Œ๋ฌธ์— eslint.config.mts๋งŒ
  no-unsafe-type-assertion์„ ๋„๋˜ ๋ธ”๋ก์„ ์ง€์šด๋‹ค. tsc -p tsconfig.json ํ†ต๊ณผ.
- prefer-token์ด ๋ถˆํˆฌ๋ช…๋„ ์ˆ˜์‹์–ด ํ† ํฐ(`paper.50/80`)์„ ํ† ํฐ์œผ๋กœ ๋ณธ๋‹ค(chakra-ui/panda#3968,
  2.2.0). Layout.tsx๋งŒ allow์— ๋„ฃ๋˜ ๋ธ”๋ก์„ ์ง€์šด๋‹ค.

lint ์œ„๋ฐ˜ 0 โ†’ 0. ํ”„๋กœ๋ธŒ(Layout.tsx์— ๋„ฃ๊ณ  ์›๋ณต): `paper.50/80`์€ ๋ณด๊ณ  ์—†์Œ, ์—†๋Š” ํ† ํฐ
`paper.999/80`๊ณผ `[8px]`(radii)๋Š” prefer-token error โ€” ํ”Œ๋Ÿฌ๊ทธ์ธ์ด ๊ทธ ํŒŒ์ผ์„ ๋ณด๊ณ  ์žˆ๋‹ค.

* perf(blog-web): ๋ธ”๋กœ๊ทธ CSS๋Š” ์“ฐ์ง€ ์•Š๋Š” keyframes๋ฅผ ์‹ฃ์ง€ ์•Š๋Š”๋‹ค

optimize.removeUnusedKeyframes๋ฅผ ์ผ ๋‹ค. 2.1.2๋Š” animations ํ† ํฐ(`animation: 'pulse'`)์œผ๋กœ๋งŒ
์ฐธ์กฐํ•œ keyframes๊นŒ์ง€ ์ง€์›Œ์„œ ๊บผ ๋‘์—ˆ๋Š”๋ฐ, 2.3.0์—์„œ ๊ณ ์ณ์กŒ๋‹ค(chakra-ui/panda#3986).

- out/ CSS์˜ @Keyframes: bounceยทpingยทpulseยทreading-progress-fillยทspin โ†’
  pulseยทreading-progress-fill. ์ผœ๊ธฐ ์ „ํ›„ CSS diff๋Š” ๋น ์ง„ ์„ธ ๋ธ”๋ก๋ฟ์ด๋‹ค.
- ์ฒซ ๋กœ๋“œ CSS gzip ์ตœ๋Œ€: 27.2 โ†’ 27.1 KB(/posts/๋Š” 27.8 KB ๊ทธ๋Œ€๋กœ). ์˜ˆ์‚ฐ 30 KB๋Š” ๊ทธ๋Œ€๋กœ ๋‘”๋‹ค โ€”
  ์ตœ๋Œ€ 27.8 KB๋กœ ๋А์Šจํ•œ ์˜ˆ์‚ฐ ํ•˜ํ•œ(80%) ์œ„๋‹ค.
- removeUnusedTokens๋Š” ๊ณ„์† ๋ˆ๋‹ค. 2.3.0์—์„œ ์ผœ ๋ณด๋ฉด code.* ๋ณ€์ˆ˜ 18๊ฐœ ์ค‘ 15๊ฐœ๊ฐ€ ์‚ฌ๋ผ์ง„๋‹ค
  (codeTheme.ts๊ฐ€ ๋Ÿฐํƒ€์ž„์— ๊ณ ๋ฅด๋Š” token.var(role)์„ ๋ชป ๋ณธ๋‹ค).
- test:e2e 83 passed.

* strict(blog-web): ๋ธ”๋กœ๊ทธ๋Š” preset-panda์˜ ๊ทธ๋ฆผ์ž ํ† ํฐ์„ ์‹ฃ์ง€ ์•Š๊ณ , ๊ทธ๋ฆผ์ž ์žฅ์‹์€ ํƒ€์ž…์—์„œ ๋ง‰ํžŒ๋‹ค

preset:resolved ํ”Œ๋Ÿฌ๊ทธ์ธ์ด preset-panda์˜ theme.tokens.shadows๋„ ๋บ€๋‹ค. ๊ทธ๋ฆผ์ž ์žฅ์‹์€ ๊ธˆ์ง€๋ผ
(AGENTS.md ยง9) ์“ฐ๋Š” ๊ณณ์ด 0์ด์—ˆ๋Š”๋ฐ ๋ณ€์ˆ˜ 11๊ฐœ๊ฐ€ ํ† ํฐ ๋ ˆ์ด์–ด์— ์‹ค๋ ธ๊ณ  `boxShadow: 'md'`๊ฐ€
ํƒ€์ž…์„ ํ†ต๊ณผํ–ˆ๋‹ค. @blog/preset์˜ `shadows.markerLeft`๋Š” ๋‚จ์•„ ์นดํ…Œ๊ณ ๋ฆฌ๊ฐ€ ๋น„์ง€ ์•Š๋Š”๋‹ค.

- out/ CSS diff๋Š” --shadows-* ์ •์˜ 11๊ฐœ๋ฟ์ด๋‹ค. ์ฒซ ๋กœ๋“œ CSS gzip ์ตœ๋Œ€ 27.1 โ†’ 27.0 KB
  (/posts/ 27.8 โ†’ 27.7), admin JS 435.1 โ†’ 434.9 KB(ํ† ํฐ ๋งต์ด ์ค€๋‹ค).
- ํ”„๋กœ๋ธŒ: `boxShadow: 'md'`๋Š” TS2769, `shadow: 'markerLeft'`๋Š” ํ†ต๊ณผ.
- ๊ฐ™์€ ์ด์œ ๋กœ ์“ฐ๋Š” ๊ณณ์ด 0์ธ blursยทdurationsยทaspectRatios๋Š” ๋‚จ๊ธด๋‹ค. ๋นผ ๋ณด๋ฉด Panda๊ฐ€ ๊ทธ ์†์„ฑ
  ํƒ€์ž…์„ `string | number`๋กœ ๋„“ํ˜€(์นดํ…Œ๊ณ ๋ฆฌ๊ฐ€ ํ†ต์งธ๋กœ ๋น„๋ฉด strictTokens๊ฐ€ ํ’€๋ฆฐ๋‹ค)
  `transitionDuration: 'fast'`ยท`backdropBlur: 'md'`ยท`aspectRatio: 'square'`๊ฐ€ ํƒ€์ž…์„ ํ†ต๊ณผํ•ด
  ๊นจ์ง„ CSS๋กœ ๋‚˜๊ฐ„๋‹ค(2.3.0 ์‹ค์ธก).
- ์˜ˆ์‚ฐ์€ ๊ทธ๋Œ€๋กœ๋‹ค: ์ตœ๋Œ€ 27.7 KB์— ~5% ์—ฌ์œ ๋ฅผ ์–น์–ด๋„ 30 KB. ๊ฐ ์ค„ ์ธก์ •๊ฐ’ ์ฃผ์„๋งŒ ์ด ๋นŒ๋“œ๋กœ ๊ฐฑ์‹ ํ•œ๋‹ค.
- optimize.removeUnusedTokens(โˆ’1.0 KB)๋Š” ์ผœ์ง€ ์•Š๋Š”๋‹ค โ€” ์‚ฌ์šฉ์ฒ˜๋ฅผ css() ์ถ”์ถœ๊ณผ ์„ค์ •์—์„œ๋งŒ ์„ธ์„œ,
  ์ฝ”๋“œ ๋ธ”๋ก ๊ตฌ๋ฌธ ๊ฐ•์กฐ๊ฐ€ ๋Ÿฐํƒ€์ž„ token.var()๋กœ ๋ถ€๋ฅด๋Š” code.* 15๊ฐœ๋ฅผ ์ง€์šด๋‹ค(์ฐจํŠธ์˜ token() ์ฐธ์กฐ๋Š”
  ์ง€๊ธˆ์€ ๋‹ค๋ฅธ css()๊ฐ€ ๊ฐ™์€ ํ† ํฐ์„ ์จ์„œ ๋‚จ์„ ๋ฟ์ด๋‹ค). smartCompoundVariants๋Š”
  compound variant 3๊ฐœ๋ฟ์ด๊ณ  ๋ณ€ํ˜• ๊ฐ’์ด ๋Ÿฐํƒ€์ž„์ด๋ผ ์ผœ์ง€ ์•Š๋Š”๋‹ค.

* strict(blog-content): ํŽ˜์ด์ง€ CSS๊ฐ€ ๋ถ€๋ฅด๋Š” keyframes๊ฐ€ ๊ทธ CSS์— ์—†์œผ๋ฉด ๋นŒ๋“œ๊ฐ€ ์‹คํŒจํ•œ๋‹ค

check-bundle์ด ํŽ˜์ด์ง€๋งˆ๋‹ค ๊ทธ ํŽ˜์ด์ง€๊ฐ€ ๋‚ด๋ ค๋ฐ›๋Š” CSS ์ „๋ถ€๋ฅผ ๋ณด๊ณ , animationยทanimation-name
์„ ์–ธ์ด ๋ถ€๋ฅด๋Š” ์ด๋ฆ„(var()๋Š” ๊ฐ™์€ CSS์˜ ์‚ฌ์šฉ์ž ์ •์˜ ์†์„ฑ์œผ๋กœ ํ‘ผ๋‹ค)์— @Keyframes ์ •์˜๊ฐ€ ์žˆ๋Š”์ง€
ํ™•์ธํ•œ๋‹ค(cssKeyframes.ts).

์ •์˜๊ฐ€ ์—†์œผ๋ฉด ๋ธŒ๋ผ์šฐ์ €๋Š” ์ง„๋‹จ ์—†์ด ์• ๋‹ˆ๋ฉ”์ด์…˜์„ ๊ฑด๋„ˆ๋›ด๋‹ค โ€” ๋กœ๋”ฉ ์Šค์ผˆ๋ ˆํ†ค(pulse)๊ณผ ๊ธ€
์ƒ์„ธ์˜ ์Šคํฌ๋กค ์ง„ํ–‰ ๋ฐ”(reading-progress-fill)๊ฐ€ ๋ฉˆ์ถ˜๋‹ค. ๋ธ”๋กœ๊ทธ๊ฐ€ optimize.removeUnusedKeyframes๋ฅผ
์ผœ๋ฉด์„œ(์ด PR) keyframes๊ฐ€ Panda ์˜ตํ‹ฐ๋งˆ์ด์ €์˜ ํŒ๋‹จ์— ๋‹ฌ๋ ธ๋Š”๋ฐ, 2.1.2์˜ ์˜ตํ‹ฐ๋งˆ์ด์ €๋Š” animations
ํ† ํฐ์œผ๋กœ๋งŒ ๋ถ€๋ฅธ keyframes๋ฅผ ์ง€์› ๋‹ค. ๋นŒ๋“œยทํƒ€์ž…ยทjsdom ํ…Œ์ŠคํŠธ๋Š” ์ƒ์„ฑ CSS๋ฅผ ๋ณด์ง€ ์•Š๋Š”๋‹ค.

- ์ด๋ฆ„ ๋ชฉ๋ก์„ ๋”ฐ๋กœ ๋‘์ง€ ์•Š๋Š”๋‹ค โ€” ๋ถ€๋ฅด๋Š” ์ด๋ฆ„์„ ์‚ฐ์ถœ๋ฌผ์—์„œ ๋ชจ์œผ๋ฏ€๋กœ ์ƒˆ ์• ๋‹ˆ๋ฉ”์ด์…˜๋„ ๋ฎ๋Š”๋‹ค.
- ์–‘์„ฑ ๋Œ€์กฐ: @Keyframes ์ •์˜๋Š” ์žˆ๋Š”๋ฐ ๋ถ€๋ฅด๋Š” ์ด๋ฆ„์„ ํ•˜๋‚˜๋„ ๋ชป ์ฐพ์œผ๋ฉด keyframes-unseen์œผ๋กœ
  ์‹คํŒจํ•œ๋‹ค(ํŒŒ์„œ๊ฐ€ ์‚ฐ์ถœ๋ฌผ ํ˜•ํƒœ๋ฅผ ๋†“์นœ ๊ฒฝ์šฐ). keyframes๋„ ์• ๋‹ˆ๋ฉ”์ด์…˜๋„ ์—†๋Š” ์‚ฌ์ดํŠธ๋Š” ํ†ต๊ณผํ•œ๋‹ค โ€”
  ์ฒ˜์Œ์—” "๋ถ€๋ฅด๋Š” ์ด๋ฆ„ 0๊ฐœ๋ฉด ์‹คํŒจ"๋กœ ๊ฑธ์—ˆ๋‹ค๊ฐ€ bundleBudgets.test.ts์˜ ์• ๋‹ˆ๋ฉ”์ด์…˜ ์—†๋Š” ํ”ฝ์Šค์ฒ˜
  ์‚ฌ์ดํŠธ๊ฐ€ ์‹คํŒจํ•ด ์ขํ˜”๋‹ค.
- ํ”„๋กœ๋ธŒ: ์‹ค์ œ out/์—์„œ "CSS keyframes ์ฐธ์กฐ 2๊ฐœ ๋ชจ๋‘ ์ •์˜๋จ". out/ CSS์—์„œ @Keyframes pulse
  33๋ฐ”์ดํŠธ๋ฅผ ์ง€์šฐ๋ฉด keyframes-missing์œผ๋กœ 100์ชฝ ์ „๋ถ€๊ฐ€ ์‹คํŒจํ•˜๊ณ (exit 1), ๋˜๋Œ๋ฆฌ๋ฉด ํ†ต๊ณผํ•œ๋‹ค.
  ๋‹จ์œ„ ํ…Œ์ŠคํŠธ๋Š” var() ํ•ด์„์„ ๋นผ๊ฑฐ๋‚˜ ํ•จ์ˆ˜ ์ œ๊ฑฐ๋ฅผ ๋นผ๋ฉด ์‹คํŒจํ•œ๋‹ค.
- ๋น„์šฉ: ๋ชจ๋“ˆ 189์ค„ยทํ…Œ์ŠคํŠธ 119์ค„, ๋นŒ๋“œ์— CSS ํŒŒ์‹ฑ(ํŽ˜์ด์ง€๋ณ„ CSS ์กฐํ•ฉ๋งˆ๋‹ค ํ•œ ๋ฒˆ โ€” ์ง€๊ธˆ์€ ๋‘ ์กฐํ•ฉ).

์žฌํ‰๊ฐ€: 2027-04-22 โ€” ๊ทธ๋•Œ๊นŒ์ง€ ๋น ์ง„ keyframes๋ฅผ ํ•œ ๋ฒˆ๋„ ์žก์ง€ ๋ชปํ–ˆ์œผ๋ฉด ์ค„์ด๊ฑฐ๋‚˜ ๋‚ด๋ฆฐ๋‹ค.

* fix(blog-content): keyframes ๊ฒ€์‚ฌ๋Š” -webkit- ์ ‘๋‘์‚ฌ ์„ ์–ธ๋„ ๋ถ€๋ฅด๋Š” ์ด๋ฆ„์œผ๋กœ ์„ผ๋‹ค

์ •์˜๋Š” `@-webkit-keyframes`๊นŒ์ง€ ์„ธ๋ฉด์„œ ๋ถ€๋ฅด๋Š” ์ชฝ์€ `-webkit-animation(-name)`์„ ๋ณด์ง€
์•Š์•„, ์ ‘๋‘์‚ฌ ์„ ์–ธ๋งŒ์œผ๋กœ ๋ถ€๋ฅธ ์ด๋ฆ„์ด ๊ฒ€์‚ฌ์—์„œ ๋น ์กŒ๋‹ค(๋ฏธํƒ ๋ฐฉํ–ฅ). ์ง€๊ธˆ out/์—๋Š” ์ ‘๋‘์‚ฌ
์„ ์–ธ์ด ์—†๋‹ค.

๋จธ๋ฆฌ ์ฃผ์„์— ๋ฒ”์œ„๋ฅผ ์ ๋Š”๋‹ค โ€” ์ฒซ ๋กœ๋“œ CSS ์•ˆ์˜ ์„ ์–ธ๋งŒ ๋ณด๊ณ , ์ง€์—ฐ ๋กœ๋“œ CSS์™€ JS๊ฐ€ ๋Ÿฐํƒ€์ž„์—
๊ณ ๋ฅด๋Š” ์• ๋‹ˆ๋ฉ”์ด์…˜(์ธ๋ผ์ธ styleยทtoken.var)์€ ๋ณด์ง€ ์•Š๋Š”๋‹ค. ํ›„์ž๋Š” Panda ์˜ตํ‹ฐ๋งˆ์ด์ €๋„ ์‚ฌ์šฉ์ฒ˜๋กœ
์„ธ์ง€ ์•Š์œผ๋ฏ€๋กœ ๋‘˜ ๋‹ค ๋†“์น˜๊ณ  e2e๋งŒ ๋ณผ ์ˆ˜ ์žˆ๋‹ค.

* strict(blog-content): keyframes ๊ฒ€์‚ฌ๋Š” ์ •์˜๊ฐ€ ์ „๋ถ€ ๋ถˆ๋ฆฌ๊ณ  ํŽ˜์ด์ง€ CSS๋ฅผ ์ „๋ถ€ ์ฝ์–ด์•ผ ํ†ต๊ณผํ•œ๋‹ค

์–‘์„ฑ ๋Œ€์กฐ keyframes-unseen("์ •์˜๋Š” ์žˆ๋Š”๋ฐ ๋ถ€๋ฅด๋Š” ์ด๋ฆ„์ด 0๊ฐœ")์„ ๋‘ ๊ทœ์น™์œผ๋กœ ๋ฐ”๊พผ๋‹ค.

- keyframes-unreferenced: ์ •์˜๋๋Š”๋ฐ ์–ด๋А ํŽ˜์ด์ง€์˜ ์„ ์–ธ๋„ ๋ถ€๋ฅด์ง€ ์•Š๋Š” keyframes๊ฐ€ ์žˆ์œผ๋ฉด
  ์‹คํŒจํ•œ๋‹ค. ๋ธ”๋กœ๊ทธ๋Š” ์“ฐ์ง€ ์•Š๋Š” keyframes๋ฅผ ๋นŒ๋“œ๊ฐ€ ์ง€์šฐ๋ฏ€๋กœ(removeUnusedKeyframes) ๋‚จ์€ ์ •์˜๋Š”
  ์ „๋ถ€ ๋ถˆ๋ ค์•ผ ํ•œ๋‹ค. ์˜ˆ์ „ ์กฐ๊ฑด์€ ์ด๋ฆ„์ด ํ•˜๋‚˜๋ผ๋„ ๋ถˆ๋ฆฌ๋ฉด ํ†ต๊ณผํ•ด์„œ, ํŒŒ์„œ๊ฐ€ var() ๊ฒฝ์œ  ํ˜•ํƒœ๋งŒ
  ๋†“์น˜๋ฉด pulse๊ฐ€ ๋น ์ ธ๋„ reading-progress-fill(์ง์ ‘ ์„ ์–ธ) ํ•˜๋‚˜๋กœ ํ†ต๊ณผํ–ˆ๋‹ค โ€” ์ด ๊ฐ€๋“œ๊ฐ€ ๋ง‰์œผ๋ ค๋Š”
  ๋ฐ”๋กœ ๊ทธ ๊ฒฝ์šฐ๋‹ค. ์˜ตํ‹ฐ๋งˆ์ด์ €๋ฅผ ๋„๋ฉด ์ด ๊ทœ์น™์ด ๋จผ์ € ์‹คํŒจํ•œ๋‹ค.
- keyframes-unread: ํŽ˜์ด์ง€๊ฐ€ ๋ถ€๋ฅด๋Š” CSS๋ฅผ ์ฝ์ง€ ๋ชปํ•˜๋ฉด ์‹คํŒจํ•œ๋‹ค. ์˜ˆ์ „์—” ๋ชป ์ฝ์€ ํŒŒ์ผ์„ ๋นˆ
  ๋ฌธ์ž์—ด๋กœ ํ•ฉ์ณ์„œ, check-bundle์˜ ๊ฒฝ๋กœ ํ•ด์„์ด ์–ด๊ธ‹๋‚˜๋ฉด ์ •์˜ยท์ฐธ์กฐ๊ฐ€ ๋‘˜ ๋‹ค 0๊ฐœ๊ฐ€ ๋˜์–ด "๋ณผ ๊ฒƒ
  ์—†์Œ"์œผ๋กœ ํ†ต๊ณผํ–ˆ๋‹ค.

ํ”„๋กœ๋ธŒ(์‹ค์ œ out/, ์›๋ณต ํ™•์ธ): ๊ทธ๋Œ€๋กœ๋ฉด ํ†ต๊ณผ. CSS์—์„œ `animation:var(--animations-pulse)`๋งŒ
์ง€์šฐ๋ฉด keyframes-unreferenced: pulse. ์ž‘์€ CSS ํŒŒ์ผ์„ ์ง€์šฐ๋ฉด keyframes-unread(์˜ˆ์‚ฐ์˜
asset-missing๊ณผ ํ•จ๊ป˜). ๋‹จ์œ„ ํ…Œ์ŠคํŠธ๋Š” ๋‘ ๊ทœ์น™์„ ๊ฐ๊ฐ ๋„๋ฉด ์‹คํŒจํ•œ๋‹ค.

---------

Co-authored-by: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[eslint-plugin] recommended() fails type-checking in eslint.config.ts (TS2322)

2 participants