Skip to content

Commit

Permalink
🩹 fix(minor): ensure unique compiler name in cache service (#2666)
Browse files Browse the repository at this point in the history
Fixes warnings related to child instances not having a unique cache identity.

## Type of change

**PATCH: backwards compatible change**
  • Loading branch information
kellymears authored Dec 9, 2024
1 parent cce6155 commit 271d22a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
1 change: 1 addition & 0 deletions sources/@roots/bud-cache/src/service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ export default class Cache extends Service implements BudCache {
*/
public get name(): string {
const fallback = join(
this.app.label,
this.app.mode,
...Object.values(this.app.context._ ?? {}),
)
Expand Down
2 changes: 1 addition & 1 deletion sources/@roots/bud-cache/test/service.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ describe(`@roots/bud-cache`, () => {
expect.arrayContaining([bud.path(`@modules`)]),
)
// @ts-ignore
expect(cache.configuration?.name).toEqual(`production`)
expect(cache.configuration?.name).toEqual(`@tests/project/production`)
// @ts-ignore
expect(cache.configuration?.profile).toEqual(false)
// @ts-ignore
Expand Down
12 changes: 6 additions & 6 deletions sources/@roots/wordpress-theme-json-webpack-plugin/src/theme.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1176,9 +1176,9 @@ export interface RefComplete {
*/
export interface StylesElementsPropertiesComplete {
button?: {
[k: string]: unknown
} &
StylesElementsPseudoSelectorsProperties & StylesProperties
[k: string]: unknown
} & StylesElementsPseudoSelectorsProperties &
StylesProperties
caption?: StylesPropertiesComplete
cite?: StylesPropertiesComplete
h1?: StylesPropertiesComplete
Expand All @@ -1189,9 +1189,9 @@ export interface StylesElementsPropertiesComplete {
h6?: StylesPropertiesComplete
heading?: StylesPropertiesComplete
link?: {
[k: string]: unknown
} &
StylesElementsPseudoSelectorsProperties & StylesProperties
[k: string]: unknown
} & StylesElementsPseudoSelectorsProperties &
StylesProperties
}
export interface StylesElementsPseudoSelectorsProperties {
':active'?: StylesPropertiesComplete
Expand Down

0 comments on commit 271d22a

Please sign in to comment.