Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove shorthand props #2138

Open
Kivylius opened this issue Sep 29, 2022 · 3 comments
Open

Remove shorthand props #2138

Kivylius opened this issue Sep 29, 2022 · 3 comments
Labels

Comments

@Kivylius
Copy link

Kivylius commented Sep 29, 2022

New teams find these shorthand properties quite confusing and its even harder to read the code over the longer properties as you need to understand whats going on. So is there any way to remove those properties and keep the rest? I just want the CSS Properties, and no psudo properties like h, w, pr. I searched and could not find anything.

@PabloLerma
Copy link

I don’t think blocking shorthand props is supported. Something you could do is blocking them using linting rules.

@Kivylius
Copy link
Author

Kivylius commented Mar 4, 2023

So it's a feature request if it's not supported? Or is there somehow for a manual overwrite. Seems strange they extended cssproperties without ability to removed them. The eslint is pretty hacky as it can be ignored.

The big issue here is inconstancy and the team then needs to agree to use one or the other, quite poor DX.

I believe it's better to have configuration over convention for consistency.

@nstanard
Copy link

@Kivylius You can override anything you want from this library by extending it and/or removing/extracting the types you don't want to include. But you have to build out the types yourself then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants