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

Feature request: Empty line setting for minimum required properties #11

Open
justrhysism opened this issue May 8, 2019 · 7 comments · May be fixed by #21
Open

Feature request: Empty line setting for minimum required properties #11

justrhysism opened this issue May 8, 2019 · 7 comments · May be fixed by #21

Comments

@justrhysism
Copy link

I like separating the properties into rational groups with lines in between - however when there's only a handful (< 3 || 4) of properties the gaps are a bit unwieldily and it makes it difficult to reason.

Suggestion: a minimum property setting for enacting the empty lines.

@jm3
Copy link

jm3 commented Jul 8, 2019

@justrhysism great idea, I've been wanting the same thing. I often find my selector rules to have lots of single-line groups which is kind of weird.

I did a quick peek at the source and ran tests (npm i; npm i -D jest-cli; npm test), and based on what I saw, I don't think I'm savvy enough about how stylelint plugins and stylelint-order work in order to hack this out myself.

Would you want to try pairing on it?

@justrhysism
Copy link
Author

justrhysism commented Jul 9, 2019

My time is limited (young kids consuming life) but I think this feature would be super useful (as is the entire plugin) so am happy to contribute :) - assuming the author is happy to accept.

@justrhysism
Copy link
Author

@jm3 alright so I've taken an initial look at this, and have realised that this plugin is basically just a configurator on top of stylelint-order.

The properties-order rule has an option emptyLineBefore which inserts the line above the group.

It appears that to get this feature in this plugin, we're going to need to add it to that plugin.

@justrhysism
Copy link
Author

Link back: hudochenkov/stylelint-order#86

@justrhysism justrhysism linked a pull request Sep 5, 2019 that will close this issue
@justrhysism
Copy link
Author

So took me a while to get there as I had to add the feature to stylelint-order first!

@zeorin
Copy link

zeorin commented Mar 14, 2020

Any movement on this? Is there a way we could use this new option while we wait for the rational order to be updated?

@justrhysism
Copy link
Author

@zeorin not sure, the project seems to be abandoned :(

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

Successfully merging a pull request may close this issue.

3 participants