-
Notifications
You must be signed in to change notification settings - Fork 16
Open
Description
When using an object with satisfies
the resolver isn't able to inject a constant at build time:
type Size = "tiny" | "small" | "medium" | "huge";
export const sizes = {
tiny: 16,
small: 24,
medium: 40,
huge: 96
} satisfies Record<Size, number>;
// imported in another file:
const Button = styled.div`
height: ${sizes.huge};
`;
fails with:
Error resolving cross-file selectors: Error resolving from module sizes.ts: Error unpacking Record/Array - unexpected exportValue "unsupported" for specifier "sizes.huge" Extracted values: { "sizes": { "type": "unsupported", "hint": "TSSatisfiesExpression" } }
Metadata
Metadata
Assignees
Labels
No labels