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

Lines between rulesets is adding lines between my imports #619

Open
bastian-hidalgo opened this issue Oct 2, 2019 · 1 comment
Open

Comments

@bastian-hidalgo
Copy link

Summary

cssCOMB is adding an empty line between @imports, how can avoid only that, because works fine but those lines are weird.

Before:

@import 'src/scss/animations'; @import 'src/scss/variables/colors'; @import 'src/scss/variables/variables'; $menu-item-width: 250px; $menu-horizontal-padding: 15px; .section-list { @extend %appear; } .container { background-color: $white; border-radius: $default-border-radius; box-shadow: $container-shadow; min-width: calc(#{$menu-item-width} + #{$menu-horizontal-padding} * 2); padding: 20px $menu-horizontal-padding 50px; }

Expected behavior:

`
@import 'src/scss/animations';
@import 'src/scss/variables/colors';
@import 'src/scss/variables/variables';

$menu-item-width: 250px;
$menu-horizontal-padding: 15px;

.section-list {
@extend %appear;
}

.container {
background-color: $white;
border-radius: $default-border-radius;
box-shadow: $container-shadow;
min-width: calc(#{$menu-item-width} + #{$menu-horizontal-padding} * 2);
padding: 20px $menu-horizontal-padding 50px;
}
`

Results

`
@import 'src/scss/animations';

@import 'src/scss/variables/colors';

@import 'src/scss/variables/variables';
$menu-item-width: 250px;
$menu-horizontal-padding: 15px;

.section-list {
@extend %appear;
}

.container {
background-color: $white;
border-radius: $default-border-radius;
box-shadow: $container-shadow;
min-width: calc(#{$menu-item-width} + #{$menu-horizontal-padding} * 2);
padding: 20px $menu-horizontal-padding 50px;
}
`

My Ruleset:

{
"csscomb.formatOnSave": true,
"csscomb.ignoreFilesOnSave": [],
"csscomb.preset": {
"remove-empty-rulesets": true,
"always-semicolon": true,
"color-case": "upper",
"block-indent": " ",
"color-shorthand": true,
"element-case": "lower",
"eof-newline": true,
"lines-between-rulesets": 1,
"leading-zero": true,
"quotes": "single",
"sort-order-fallback": "abc",
"sort-order": ["$extend"],
"space-before-colon": "",
"space-after-colon": " ",
"space-before-combinator": " ",
"space-after-combinator": " ",
"space-between-declarations": "\n",
"space-before-opening-brace": " ",
"space-after-opening-brace": "\n",
"space-after-selector-delimiter": "\n",
"space-before-selector-delimiter": "",
"space-before-closing-brace": "\n",
"strip-spaces": true,
"tab-size": true,
"unitless-zero": true
},
"csscomb.supportEmbeddedStyles": true,
"csscomb.syntaxAssociations": {},
}

@Quirksmode
Copy link

I am having the exact same issue, did you manage to solve?

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

No branches or pull requests

2 participants