Skip to content

Commit 461dbe8

Browse files
chriseppsteinamiller-gh
authored andcommitted
feat(css-blocks): Casting through object is sufficient.
1 parent 03dba9b commit 461dbe8

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

packages/css-blocks/src/Block/BlockTree/Inheritable.ts

+1-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
* @module Block/BlockTree/Inheritable
1313
*/
1414
import { ObjectDictionary } from "@opticss/util";
15-
import { whatever } from "@opticss/util";
1615

1716
import { SourceLocation } from "../../SourceLocation";
1817

@@ -205,7 +204,7 @@ export abstract class Inheritable<
205204
// TypeScript can't figure out that `this` is the `Self` so this private
206205
// method casts it in a few places where it's needed.
207206
private asSelf(): Self {
208-
return <Self><whatever>this;
207+
return <Self><object>this;
209208
}
210209

211210
}

packages/css-blocks/src/Block/BlockTree/Style.ts

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import { Attr } from "@opticss/element-analysis";
2-
import { whatever } from "@opticss/util";
32

43
import { OptionsReader } from "../../OptionsReader";
54
import { unionInto } from "../../util/unionInto";
@@ -116,7 +115,7 @@ export abstract class Style<
116115
// TypeScript can't figure out that `this` is the `StyleType` so this private
117116
// method casts it in a few places where it's needed.
118117
private asStyle(): Self {
119-
return <Self><whatever>this;
118+
return <Self><object>this;
120119
}
121120
}
122121

0 commit comments

Comments
 (0)