Skip to content

fix(css): make sass types work with sass-embedded#18459

Merged
patak-cat merged 4 commits intovitejs:mainfrom
sapphi-red:fix/make-sass-types-work-with-sass-embedded
Oct 25, 2024
Merged

fix(css): make sass types work with sass-embedded#18459
patak-cat merged 4 commits intovitejs:mainfrom
sapphi-red:fix/make-sass-types-work-with-sass-embedded

Conversation

@sapphi-red
Copy link
Member

@sapphi-red sapphi-red commented Oct 25, 2024

Description

Built on top of #18458

The types did not work when sass-embedded was installed instead of sass.

@sapphi-red sapphi-red added feat: css p3-minor-bug An edge case that only affects very specific usage (priority) labels Oct 25, 2024
@sapphi-red sapphi-red changed the title Fix/make sass types work with sass embedded fix(css): make sass types work with sass-embedded Oct 25, 2024
@sapphi-red sapphi-red marked this pull request as draft October 25, 2024 08:28
Comment on lines +120 to +130
"packageExtensions": {
"sass-embedded": {
"peerDependencies": {
"source-map-js": "*"
},
"peerDependenciesMeta": {
"source-map-js": {
"optional": true
}
}
}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was needed to make the type-check happy.

Comment on lines +14 to +15
// https://github.com/type-challenges/type-challenges/issues/29285
type IsAny<T> = boolean extends (T extends never ? true : false) ? true : false
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interestingly, the mosted 👍 ed answer (type-challenges/type-challenges#232) didn't work in our case.

@sapphi-red sapphi-red marked this pull request as ready for review October 25, 2024 13:30
Copy link
Member

@bluwy bluwy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for polishing up the types!

@patak-cat patak-cat merged commit 89f8303 into vitejs:main Oct 25, 2024
@sapphi-red sapphi-red deleted the fix/make-sass-types-work-with-sass-embedded branch October 26, 2024 06:47
moonlitusun pushed a commit to moonlitusun/vite that referenced this pull request May 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feat: css p3-minor-bug An edge case that only affects very specific usage (priority)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants