SassDoc / sass-convert

[umaintained] Node.js bindings to sass-convert.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Ignore Sass Maps by default?

brograhamer opened this issue · comments

When saving a file my Sass maps turn into one line, which is not good for readability. The following is a short example, but it gets messier when an extensive, nested map (map-deep-get) is parsed:

Before:

$colors: (
    one: #113751,
    two: #f5c71f,
    three: #0085ba,
    light: #E5E5E5,
    medium: #475058,
    dark: #23282d
);

After:

$colors: (one: #113751, two: #f5c71f, three: #0085ba, light: #E5E5E5, medium: #475058, dark: #23282d);

Nested Map:

$heading: (color: ("h1": color("dark"), "h2": color("dark"), "h3": color("dark"), "h4": color("dark"), "h5": color("dark"), "h6": color("dark")), desktop: ("h1": 48px, "h2": 40px, "h3": 28px, "h4": 28px, "h5": 24px, "h6": 20px), tablet: ("h1": 35px, "h2": 30px, "h3": 26px, "h4": 26px, "h5": 22px, "h6": 20px), mobile: ("h1": 30px, "h2": 26px, "h3": 23px, "h4": 23px, "h5": 20px, "h6": 20px), font-family: font("heading"), font-weight: ("h1": 400, "h2": 400, "h3": 400, "h4": 400, "h5": 400, "h6": 400), line-height: 1.1, letter-spacing: 0, margin-bottom: ("h1": 15px, "h2": 15px, "h3": 15px, "h4": 15px, "h5": 15px, "h6": 15px), text-transform: ("h1": none, "h2": none, "h3": none, "h4": none, "h5": none, "h6": none)) !default;

Is there any way we can ignore maps all together from being parsed? This would be a major win for me.

Hi,

all the parsing and data transforms are done by the sass-convert binary, so from Ruby Sass.
There's nothing we can do here I'm afraid.